473,387 Members | 1,834 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Helpful tools to become a really fast and good c-programmer

Hi,

As I been programming in C I have discovered more and more tools that
really helps to speed up the development process when writing
programs. Examples of such tools are cscope, cbrowser, tags, etc.

There are ofcourse many different levels of programmers, and the
beginners might only use emacs or vi to write their code. However,
since there are such great tools out there to help the programmer, I
am wondering which tools are considered to be the best and most
effective?

In other words, what kind of tools are the "elite" programmers using?
I am sure they are not just using a simple editor..

It would be really interesting to get some opinions on which tools
speed up the development process the most. I would say that cscope
with cbrowser is the most effective tool to help the development
process, especially if there is a lot of new code to get into.

Best regards
Nov 14 '05 #1
8 1962
markus wrote:
.... snip ...
In other words, what kind of tools are the "elite" programmers
using? I am sure they are not just using a simple editor..


On the contrary, that is just what they are using.

--
Some useful references:
<http://www.ungerhu.com/jxh/clc.welcome.txt>
<http://www.eskimo.com/~scs/C-faq/top.html>
<http://benpfaff.org/writings/clc/off-topic.html>
<http://anubis.dkuug.dk/jtc1/sc22/wg14/www/docs/n869/> (C99)
<http://www.dinkumware.com/refxc.html> C-library
Nov 14 '05 #2
markus wrote:
Hi,

As I been programming in C I have discovered more and more tools that
really helps to speed up the development process when writing
programs. Examples of such tools are cscope, cbrowser, tags, etc.

There are ofcourse many different levels of programmers, and the
beginners might only use emacs or vi to write their code. However,
since there are such great tools out there to help the programmer, I
am wondering which tools are considered to be the best and most
effective?

In other words, what kind of tools are the "elite" programmers using?
I am sure they are not just using a simple editor..


I'm not sure that it's an *exclusive* thing. I use cscope, tags, etc...
IN CONJUNCTION WITH vi. I suspect most "elite" (as you call them)
programmers don't see it as an either-or thing as well, but rather, "use
the right toolset for the job".

I've been writing C for over 20 years (Holy shit, it really has been
that long), and I prefer vi/makefiles/cc to any IDE, becuase I *KNOW*
what's going on. I use Visual Studio in my current job (not my choice),
and I can't stand it, partly because I'm not sure what's going on under
the hood....

Of course, I might just be a control freak.
Nov 14 '05 #3
In article <41***************@yahoo.com>,
CBFalconer <cb********@worldnet.att.net> wrote:
markus wrote:

... snip ...

In other words, what kind of tools are the "elite" programmers
using? I am sure they are not just using a simple editor..


On the contrary, that is just what they are using.


Yes. More often than not, those tools (IDE, etc) are created for, and used
by, the less capable. Not that there is anything wrong with being less
capable.
Nov 14 '05 #4
CBFalconer wrote:

markus wrote:

... snip ...

In other words, what kind of tools are the "elite" programmers
using? I am sure they are not just using a simple editor..


On the contrary, that is just what they are using.

All of my career has been spent either using Integrated Developement
Evironment tools or standalone editor, compiler and debugger sets.
Sometimes (like my current setup at home) I don't even bother with a
debugger.

Brian Rodenborn
Nov 14 '05 #5
Hi markus,

There are ofcourse many different levels of programmers, and the
beginners might only use emacs or vi to write their code. However,
since there are such great tools out there to help the programmer, I
am wondering which tools are considered to be the best and most
effective?

In other words, what kind of tools are the "elite" programmers using?
I am sure they are not just using a simple editor..


Brain, editor, compiler. In that order.
Apart from that: Debugger, manfiles or other library documentation.
Everything else depends.

If the code you want to produce or work at is huge:
- make
- tags
- some documentation generator
- cvs, diff, patch

If it is s.th. new to you, typically huge, largely undocumented, go
at it with
- tags
- some documentation generator

If the modules are comparatively small, not all by you and probably
bugridden
- compiler warnings
- splint (-weak|-normal)
- some documentation generator

If you are going to work with it every day for a long time:
- get to know the environment and tailor your own tools
It is nice to have the perfect environment for your work. In my
experience, "perfect" depends on the task at hand. A certain IDE
might be exactly the right thing for providing short event-handling
routines, but too opaque for doing something else.
Apart from that: If you are not very sure that it will be only for
a short time, then get the standard tools working you think necessary.

Having a good coding style is more important. Good meaning: producing
easy-to-maintain, safe etc code in an efficient manner. But even these
things depend on whether you are working alone, in a team with
colleagues or in an open source project with everyone and no one.
Cheers,
Michael

Nov 14 '05 #6
On 16 Aug 2004 01:49:21 -0700, ds****@hotmail.com (markus) wrote in
comp.lang.c:
Hi,

As I been programming in C I have discovered more and more tools that
really helps to speed up the development process when writing
programs. Examples of such tools are cscope, cbrowser, tags, etc.

There are ofcourse many different levels of programmers, and the
beginners might only use emacs or vi to write their code. However,
since there are such great tools out there to help the programmer, I
am wondering which tools are considered to be the best and most
effective?

In other words, what kind of tools are the "elite" programmers using?
I am sure they are not just using a simple editor..

It would be really interesting to get some opinions on which tools
speed up the development process the most. I would say that cscope
with cbrowser is the most effective tool to help the development
process, especially if there is a lot of new code to get into.

Best regards


Others have written some good answers, but I am rather surprised that
no one has mentioned lint. There is a commercial implementation for
Windows from http://www.gimpel.com and an open source version
available at http://www.splint.org.

I have never used splint, but Gimpel's PC Lint is worth its weight in
gold. It takes some effort to customize it to your style and the type
of programming that you do, but it can repay that initial time dozens
of times over.

--
Jack Klein
Home: http://JK-Technology.Com
FAQs for
comp.lang.c http://www.eskimo.com/~scs/C-faq/top.html
comp.lang.c++ http://www.parashift.com/c++-faq-lite/
alt.comp.lang.learn.c-c++
http://www.contrib.andrew.cmu.edu/~a...FAQ-acllc.html
Nov 14 '05 #7
ds****@hotmail.com (markus) wrote in message news:<bc**************************@posting.google. com>...
Hi, Examples of such tools are cscope, cbrowser, tags, etc. ... There are ofcourse many different levels of programmers, and the beginners might only use emacs or vi to write their code. However, since there are such great tools out there to help the programmer


I find ctags more useful than cscope in general. In particular I use
the ctags formerly bundled with Vim (exuberant ctags) (off-topic:
works well with other languages too, as diverse as ASP, Python, Java,
Scheme, and Fortran to name a few). And of course find and grep are
incredibly useful on large source trees.

make integration with the editor (as vim and emacs do naturally) is
nice.

Anyway, I find that 98% or more of development is done with a simple
editor and compiler. Other useful tools:

gdb (or whatever your debugger of choice is). You can pretty easily
wire it up so that a segfault (SIGSEGV) fires up a debugger, attaches
to the current process, and gives a stack trace. Can be somewhat
handy.

strace (or truss) to trace system calls

ltrace to trace library calls

For some applications, lsof and netstat (to list open files and
network sockets)

ElectricFence, a memory debugger. Very handy if you've got memory
problems (those mysterious segfaults usually get moved up to where
invalid memory access first happened)

The Boehm-weiser garbage-collecting malloc implementation can be
compiled in a memory leak detection mode that I've found helpful a
couple of times (especially if you're debugging a big third-party app
with memory leaks)

CVS or Subversion (or equivalent); I find it useful to version my
files even when I'm working alone, so I can more freely try out
different approaches.

I still find myself doing printf debugging most of the time (to the
point that I get familiar with http -X for large web applications or
equivalent ways of making sure I can run synchronously and on
console).

And of course, getting a second pair of eyeballs to look at things is
handy.

Failing that, it's useful to pretend you're writing to a newsgroup for
advice and go through all the steps they would ask you for ("They're
going to want a minimal test case. Okay, I'll write one. They're
going to ask if I've tried this edge case. Okay, done. They're going
to ask if I've tried this edge case. Okay, done."). It's amazing how
often I can find a bug that I've spent a half hour or more chasing if
I just sit down and approach it from that perspective ("They're going
to ask if I've tried passing zero to that function--oh, wait, that's
not right. Duh, what a stupid bug.").

Worst case you can post a message that has the minimal test case and a
list of all the things you've tried.
Nov 14 '05 #8
boa
markus wrote:
Hi,

As I been programming in C I have discovered more and more tools that
really helps to speed up the development process when writing
programs. Examples of such tools are cscope, cbrowser, tags, etc.

There are ofcourse many different levels of programmers, and the
beginners might only use emacs or vi to write their code. However,
since there are such great tools out there to help the programmer, I
am wondering which tools are considered to be the best and most
effective?

In other words, what kind of tools are the "elite" programmers using?
I am sure they are not just using a simple editor..

It would be really interesting to get some opinions on which tools
speed up the development process the most. I would say that cscope
with cbrowser is the most effective tool to help the development
process, especially if there is a lot of new code to get into.

Best regards

- The assert() macro is quite useful, both for asserting that function
parameters are correct and for asserting that my own code is correct.

- Module test programs are always good. Takes some time to write, but is
nice to have when that hard to find bug comes along. gcov or similar
programs can help you check that the test programs test all the code.

- valgrind, http://valgrind.kde.org, is a *very* useful tool on Linux
platforms. If you're on Linux, do yourself a favor and try valgrind.

- A profiler, e.g. gprof, is also a good idea to use to find performance
bottlenecks. Use a profiler to find the bottlenecks instead of wasting
hours/days optimizing non-critical code.

- Keeping it simple is always a good idea. As K&P said, IIRC, debugging
is twice as hard as writing code, so if you write the most complicated
code you can, you won't be able to debug it..

- A good tool is your brain. Don't be sloppy, but write code the way you
*know* it is supposed to be written even if it taks a little bit longer.
HTH
boa@home
Nov 14 '05 #9

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

15
by: Bart | last post by:
What is the best tool to develop a php-website ? I used Macromedia Dreamweaver MX and Zend Studio. Are there better tools ? Bart
43
by: grz02 | last post by:
Hi, Im an experienced database+software designer and developer, but, unfortunately, anything to do with web-programming and web-systems designs is still a pretty new area to me... (been working...
31
by: Carlos Ribeiro | last post by:
Hello all. I'm in the process of writing a business app in Python. (defining business app: data entry, validation, interactive reports, etc). For my purposes, it must be a native app (wxWidgets,...
72
by: Mel | last post by:
Are we going backwards ? (please excuse my spelling...) In my opinion an absolute YES ! Take a look at what we are doing ! we create TAGS, things like <H1> etc. and although there are tools...
3
by: p_kolya | last post by:
Hello! I looking for a good tool for working with .ini files fast and easy. boost::spirit can do all what I want... but I think it's too heavy for me :) May be there are other standart tools to...
12
by: CppNewB | last post by:
I am absolutely loving my experience with Python. Even vs. Ruby, the syntax feels very clean with an emphasis on simplification. My only complaint is that there doesn't appear to be a great...
19
by: dba_222 | last post by:
Dear Experts, I've worked with Oracle since 1995. I have gone very deep into many of the Oracle features, including sqlloader, and export/import. And I've done data modelling even longer. ...
6
by: Anastasios Hatzis | last post by:
Hello, I'm working on the light-weight MDA tool pyswarm, http://pyswarm.sourceforge.net/ (it is about a code-generator for Python/PostgreSQL-based software. I plan to add support of UML CASE...
23
by: mike3 | last post by:
Hi. (posted to both newsgroups since I was not sure of which would be appropriate for this question or how specific to the given language it is. If one of them is inappropriate, just don't send...
5
by: =?ISO-8859-1?Q?Ren=E9?= | last post by:
Hi, I'm having serious issues with our user defined functions. They get very slow after a while. The functions I use have several IF-branches which check input parameters. Always exactly one...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.