Home arrow C programming

Language Translator

Hacking Zone

Hacking Tools
Attacking

Configure Windows

Windows Configuration

Mix Tutorials

Asterisk
Website Building

Novels

Mix Novels

Human Personality

Body Language
C programming

    All Latest C Programming related articles. to submit your articles became a membur, it's free or send your article to publisher(at)tutorialsforu(dot)info.

 



Optimizing C and C++ Code Print E-mail

Optimizing C and C++ Code

 

                Embedded software often runs on processors with limited computation power, thus optimizing the code becomes a necessity. In this article we will explore the following optimization techniques for C and C++ code developed for Real-time and Embedded Systems. 

  1. Adjust structure sizes to power of two
  2. Place case labels in narrow range
  3. Place frequent case labels first
  4. Break big switch statements into nested switches
  5. Minimize local variables
  6. Declare local variables in the inner most scope
  7. Reduce the number of parameters
  8. Use references for parameter passing and return value for types bigger than 4 bytes
  9. Don't define a return value if not used
  10. Consider locality of reference for code and data
  11. Prefer int over char and short
  12. Define lightweight constructors
  13. Prefer initialization over assignment
  14. Use constructor initialization lists
  15. Do not declare "just in case" virtual functions
  16. In-line 1 to 3 line functions

 

Read more...
 
Code Optimization Using the GNU C Compiler Print E-mail

Code Optimization Using the GNU C Compiler

 

This article describes some of the code optimization techniques used by the GNU C Compiler, in order to give the reader a feel of what code optimization is and how it can increase the efficiency of the generated object code.

Contents

  1. Introduction
  2. Assembly Language Code for a C Program
  3. Constant Folding
  4. Common Subexpression Elimination
  5. Dead Code Elimination
  6. Strength Reduction using Induction Variable
  7. Conclusion
  8. Acknowledgments
  9. References

 

Read more...
 
C optimisation tutorial Print E-mail

C optimisation tutorial

 

            This document has evolved over time and contains a number of the best ways to hand-optimise your C-code. Compilers are good, but they can't do everything, and here I hope to help you squeeze the best performance out of your code. This is not intended for beginners, but for more experienced programmers. 

Read more...
 
Guide to Network Programming Print E-mail

Guide to Network Programming

 

                Hey! Socket programming got you down? Is this stuff just a little too difficult to figure out from the man pages? You want to do cool Internet programming, but you don't have time to wade through a gob of structs trying to figure out if you have to call bind() before you connect(), etc., etc.

Well, guess what! I've already done this nasty business, and I'm dying to share the information with everyone! You've come to the right place. This document should give the average competent C programmer the edge s/he needs to get a grip on this networking noise.

Read more...
 
A TUTORIAL ON POINTERS AND ARRAYS IN C - Part 4 Print E-mail

Pointers to Functions

 

        One of those things beginners in C find difficult is the concept of pointers. The purpose of this tutorial is to provide an introduction to pointers and their use to these beginners.

Read more...
 
A TUTORIAL ON POINTERS AND ARRAYS IN C - Part 3 Print E-mail

Pointers and Dynamic Allocation of Memory

   

           One of those things beginners in C find difficult is the concept of pointers. The purpose of this tutorial is to provide an introduction to pointers and their use to these beginners.

Read more...
 
A TUTORIAL ON POINTERS AND ARRAYS IN C - Part 2 Print E-mail

 Pointers and Structures,MultiDimentional Arrays, pointer to arrays

 

                One of those things beginners in C find difficult is the concept of pointers. The purpose of this tutorial is to provide an introduction to pointers and their use to these beginners.

Read more...
 
A TUTORIAL ON POINTERS AND ARRAYS IN C - Part 1 Print E-mail

A TUTORIAL ON POINTERS AND ARRAYS IN C

        

      One of those things beginners in C find difficult is the concept of pointers. The purpose of this tutorial is to provide an introduction to pointers and their use to these beginners.

 

Read more...
 
<< Start < Prev 1 2 Next > End >>

Results 1 - 13 of 14
Your Ad Here

RSS socialnet

Add to MyYahoo!
Subscribe in NewsGator Online
Add to Newsburst
Add to Google
Add to My AOL
Add to Pluck
Subscribe in FeedLounge
Add to Windows Live
Add to NetVibes
Subscribe in Rojo
Subscribe in Bloglines
Add to MyMSN
Add to Plusmo for your cellphone
Add to PageFlakes
Add to Technorati
Add to BlinkBits