Which IDEs have good support for programming with CUDA? [closed] - c

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 9 years ago.
Improve this question
I'm starting to do programming with CUDA C. Are there any IDE that are especially good for programming with it?
I'm using a windows machine and a personal macbook :D (But I want to know what people use in linux and mac also)

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

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:
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.
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.
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.
there is a thread on nvidia for this as well http://forums.nvidia.com/index.php?showtopic=91057

In windows you can use NVIDIA Parallel Nsight Visual 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 distro which 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)

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.

Related

Linux-native C libraries: How to configure Visual Studio Code to work with them on Windows?

total noob here.
There are a few a few C libraries I would like to use, like unistd.h and sys/time.h, in a Windows machine. I have found many threads discussing is it simply not possible without using alternative packages. But I wonder does the Windows Subsystem for Linux come with those libraries? If so, how do I configure Visual Studio Code work with WSL?
But I wonder does the Windows Subsystem for Linux come with those
libraries?
Yes compiler in WSL will contain these headers.
If so, how do I configure Visual Studio Code work with WSL?
You need to enable WSL in Windows features, install linux distro you like via Microsoft Store, install "Remote - WSL" extension in VS Code.
More information can be found here: https://code.visualstudio.com/docs/remote/wsl
Keep in mind though, that applications that you will compile in this setup will be linux applications. They will only be able to operate under linux or WSL.
There is no way you can compile applications using these libs for Windows. These libs are platform depended.

C compiler for MS-DOS [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 5 years ago.
The community reviewed whether to reopen this question 8 months ago and left it closed:
Original close reason(s) were not resolved
Improve this question
I have installed MS-DOS 6.22 on a VirtualBox virtual machine, everything is working well, the purpose of doing that is to compile a program written in the C language that displays and edits bits in the (virtual) RAM. However, I need a way to install a C compiler on the virtual MS-DOS operating system.
Here are a bunch of details others have missed:
Nobody mentioned DJGPP at all.
It's a protected-mode DOS port of GCC and probably has the largest selection of libraries and guides available of any of the open-source options. (Including a Turbo Vision port with an installation HOWTO)
No matter what you're trying to do, OpenWatcom (source) is likely to meet your needs.
OpenWatcom still includes the free license to use DOS/4GW that made it so popular back in the day. (When you see a game like DOOM saying "DOS/4GW Protected Mode Runtime" when it starts, that means that it was built using Watcom C/C++, because DOS/4GW is the special Watcom bundle version of DOS/4G.)
In fact, DOS/4GW's creator was trying to dig up the source code for a newer version of DOS/4GW to contribute to Open Watcom when he passed away.
If you don't want nostalgia, OpenWatcom bundles newer, better alternatives to DOS/4GW, like DOS/32 and PMODE/W.
If you want to putter around with Windows 3.1 programming, OpenWatcom includes Win386, a 32-bit extender for Window 3.x which was used by companies like Sierra for their Windows 3.1 games before Microsoft produced their own "Win32s" 32-bit API addon.
OpenWatcom can target all supported platforms from a single install. (I use it to build various DOS and Windows test EXEs from Linux.)
OpenWatcom can target a lot of retro-platforms:
COM files
real-mode EXEs (there's a separate set of options to select minimum CPU requirement)
protected-mode EXEs (with your choice of several extenders)
Windows 3.1 EXEs (with or without the Win386 extender)
Lots of other formats you probably don't care about
If your project must run in real mode (ie. no DJGPP) and you want something with a more modern optimizer than the one in Open Watcom C/C++, there's a fork of GCC named GCC IA16 that you can try. (Though I don't know how complete its support is for the various memory models and calling conventions used in the 16-bit x86 ecosystem.)
If you want something that'll let you run the IDE and compiler on ancient hardware, the Pacific C compiler and IDE list a 286 CPU as their minimum requirement but can also be run in DOSEMU for easy integration into Linux-based build automation.
Here are a few other free C compilers for DOS, though they lack the huge ecosystems DJGPP and OpenWatcom have:
CC386
DeSmet C
Dev86
Orange C/C++ Compiler
You may also want to run the UPX compressor on the EXE files you build so you'll have more free space on any floppy images you make. (Don't forget to run it with --8086 if you're targeting something older than a 386.)
It's capable of compressing EXE, COM, and SYS files and using this sort of executable compression was commonplace back in the day.
(However, two of the three major formats UPX doesn't compress are OS/2 and Windows 3.1 executables. I'm still looking into the best option for those, given that LxLite doesn't get along with OpenWatcom-generated EXEs.)
The Turbo C compiler for DOS is just awesome, and freeware.
Official site link
http://edn.embarcadero.com//article/20841
Also there are Microsoft QuickC but I don't know how hard is to find it.
Or Watcom C, but I don't know if their OpenWatcom version works with DOS
I have installed the compiler and it worked successfully, if you want the ova here is the link
MS-DOS ova with C compiler
To open the compiler:
cd TC
TC
and that's it! You can write C and compile. The best part is that you can deal with registers and memory without any restriction.
You may want to try Open Watcom or Borland Turbo Series. There are other options but best are those 2 imho.
There are a number of compilers here:
http://www.compilers.net/dir/free/compilers/ccpp.htm
Very specifically, I have used the "Pacific C" for several different fun projects and I was pleased with both the ease of use and overall compatibility.
I was able to chase down a new URL for the download:
http://www.ibiblio.org/pub/micro/pc-stuff/freedos/files/devel/c/pacific/
You might want to take a look at FreeDOS, it includes a suite of development tools.
Open Watcom has a C compiler that will work on DOS: Open Watcom
You can save it and then create a virtual floppy with it: virtual floppy how to
This should let you install it on your virtual machine.
The Borland C++ 4.53 is the most capable, as it can output DOS (in all memory models) and Windows 3.1 and 95 executables, from several IDEs, either a DOS or Windows one. It includes command line tools, but again, it has to be hosted on a PC platform or something like DOSBox.
This original package for Borland C 4 was fairly hefty, but not nearly as insane as the literal bookshelf which came with Borland C++ 3.1. Borland C++ 3.1 is more than likely the heaviest and largest retail commercial software product box in history.
Embarcadero Technologies has released Borland C++ compiler as freeware some time ago. Sadly there's no IDE, only command line tools.

Is there an IDE that works with CUDA on mac osx lion?

I'm trying to learn Cuda and its very interesting but I'm having problems creating code without a bit of help from an IDE. I know Java/Python but I'm unfamiliar with C/C++ so I have been using eclipse and Xcode to help me with commands and finding things(via code code completion). I can't seem to get these options for CUDA?
I have seen examples and can build them find(nvcc is working) but without the IDE to help catch some of my mistakes I'm a bit lost editing the code in just a text editor. I found a toolkit plugin for eclipse but although it seems to install I think its for a older build of eclipse because most of the options in the instructions do not match my version(Indigo). Nvidia has a plugin for Visual studio only on their site(I'd rather not install windows on my mac to use Cuda).
I'm sorry if this sounds bad but I'm curious to how people are developing cuda on Mac's. I don't care what IDE I use as long as it helps me see the options and warn me if I have syntax issues,etc..(I'm not the best programmer but switching IDE's for me has just been a matter of finding out where things are so I'm really fine with any solution as long as it helps me as I'm learning).
Nsight Eclipse Edition is available as a part of the CUDA Toolkit 5.0 (no additional download required).
Qt Creator!
You can read Qt Creator + CUDA + Linux for inspiration on how to setup the build environment on Mac OS X.
You could think about using JCuda:
http://www.jcuda.de/
There is XCode plug-in for CUDA development. I found it there. There is the main discussion on nvidia.com
Visual Studio Code + this extension:
https://github.com/gangliao/VS-Code-Cuda.
For me, Visual Studio Code is my favorite IDE for every language I found out there

Best gui for remote gdb [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
I know this question has been brought up before but it was mostly in respect to gdb for a program running on the local machine.
I've had some success with eclipse-cdt but it only seems to work occasionally. Supposedly Insight was previously used to debug (this embedded x86 board) but it seems to be dead.
I only need C debugging not C++. If possible I would prefer to connect through gdbserver (as that is on the advice and I connect to it through the command line all the time) but if you think putting gdb or ssh on the device and using it through those is better please mention those solutions also.
P.S. The version of gdbserver on the device is 7.1 it would be nice if the solution can work with a compatible version of gdb but I might be able to install a different gdbserver version.
I'd recommend eclipse Indigo it has built-in support for remote debugging applications via gdbserver. I just don't know where the source code has to be located for it to work.
Sinec it uses the MI interface of gdb it should work as any other interface that interacts with gdb.
I recommend trying out Qt Creator. It's cross-platform, has pretty good "code insight" features, and is a hell of a lot lighter-weight than Eclipse. It is a full IDE, not just a debugger front-end. It does require a gdb built with python support (client only, I think), but does come with it in its cross-platform installer. It is definitely more geared to developing C++/Qt applications, but does support generic Makefile and CMake projects, and I use it as my everyday C IDE and debugger.
Depending on exactly what kind of remote target you're debugging, the answer to this question could vary a lot. If you're cross-debugging to a deeply embedded microcontroller target running an RTOS, your options are going to be more limited.
For Makefile-based projects, you want to use the "Generic Project" creation wizard, which by default adds all the source files under the specified directory to your project. It may take some manual work to maintain your project, if you want Qt Creator to "understand" things that you've specified in your Makefile like command-line include directories (go in your .includes file), command-line included headers (go in your .config file), and command-line symbol definitions (go in your .config file). The project file list and compile, deploy, and run commands can all be maintained from the GUI though.
How about using DDD? I haven't used it much to be honest, and there seems to be a way to do remote debugging using DDD http://www.gnu.org/s/ddd/manual/html_mono/ddd.html#Remote%20Program
Gdb itself has already built-in curses based pseudo gui. By default, it splits main screen on 2 windows. Upper window contains source code, lower window is command line interface. Also there are other modes allowing to show you register values and assembly. It works well over ssh, so if you can, copy gdb on your device and debug it over ssh. If not, everything above can be applied for debugging over gdbserver.
You can use NetBeans. NetBeans support remote debugging with gdb. Gdbserver support plug-in also exist. I don't test plug-in but remote debugging using ssh working well.
Try Affinic Debugger GUI. It has newer design.
DDD is too old, Affinic Debugger supports all major platforms and is more powerful than DDD.

Running linux gcc-compiled program under windows [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about programming within the scope defined in the help center.
Closed 2 years ago.
Improve this question
Ok, guys, hope this is quite a simple question:
is there any way to run a C program compiled under linux with gcc on a windows operating system?
Please don't tell me to recompile it under windows, since I already tried but looks like no c windows compiler has 128 bit native type, and using bignum libraries makes my program like 10 to 100 times slower.
Is there any way to actually RUN the linux binary under windows?
Someone told me something about cygwin, but I don't know where to get started with it. (My program should be portable as well, so I souldn't need to install programs and stuff on my machine).
Thank you very much!!
Matteo
No direct way. A Linux executable has a radically different format than Windows. There are several other options.
cygwin. Compile the program with GCC under cygwin. I believe that will build a windows exe that uses the cygwin compatibility layer.
install a VM like VBox. Install a Linux in the VBox. Run the program there.
http://www.andlinux.org has a framework for doing this. I've never tried it, but there is a video tutorial http://www.youtube.com/watch?v=nULDHPCm9p4.
It seems to me, that flinux could do it.
From the description:
... is a dynamic binary translator ... capable of running unmodified Linux binaries on Windows ...
Note: I've not tested this.
Please don't tell me to recompile it
under windows
You'll have to recompile it under Windows. Sorry!
If you really can't find a compiler with support for 128 bit integers you should use some assembler to replicate the instructions that you Linux compiler emits.
Since Windows 10 Anniversary Update, Windows is able to natively run Linux binaries via Windows Subsystem for Linux (WSL), commonly known as Bash on Ubuntu on Windows.
See https://msdn.microsoft.com/en-us/commandline/wsl
After installation, you can open a bash session, navigate to /mnt/<driveletter>/<path to your program> and run your executable as if you were running Linux.
Note: WSL is still beta.
Use a Virtual machine for Linux as Guest OS on your Host Windows OS. Run your executable under the VM. But compiling under gcc-cygwin combine is best bet.

Resources