Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Book Overview & Buying Systems Programming with C# and .NET
  • Table Of Contents Toc
Systems Programming with C# and .NET

Systems Programming with C# and .NET

By : Vroegop
5 (3)
close
close
Systems Programming with C# and .NET

Systems Programming with C# and .NET

5 (3)
By: Vroegop

Overview of this book

If you want to explore the vast potential of C# and .NET to build high-performance applications, then this book is for you. Written by a 17-time awardee of the Microsoft MVP award, this book delves into low-level programming with C# and .NET. The book starts by introducing fundamental concepts such as low-level APIs, memory management, and performance optimization. Each chapter imparts practical skills, guiding you through threads, file I/O, and network protocols. With a focus on real-world applications, you’ll learn how to secure systems, implement effective logging, and deploy applications seamlessly. The book particularly emphasizes debugging, profiling, and addressing challenges unique to multithreaded and asynchronous code. You’ll also gain insights into cybersecurity essentials to help you safeguard data and establish secure communications. Moreover, a dedicated chapter on systems programming in Linux will help you broaden your horizons and explore cross-platform development. For those venturing into embedded systems, the final chapter offers hands-on guidance. By the end of this book, you’ll be ready to deploy, distribute, and maintain applications in production systems.
Table of Contents (18 chapters)
close
close

Compiler optimizations

I have said it before and will repeat it here: don’t try to outsmart the compiler. The C# compiler is a fantastic piece of software that can do tricks we can’t even think of. But sometimes, we can help the compiler make choices that affect performance in a good way.

Aggressive optimization

Look at the following method:

private int AddUp(int a, int b)
{
    return a + b;
}

I am sure you agree that this is not an exciting method. Calling this, however, does take a lot of time: the calling method has to store the return address, move all parameters (the integer values, a and b) to the right place, jump to the method, retrieve the parameters, do the actual work, store the return value in the right place, retrieve the return address, jump to that return address, and assign the result to the variable in the calling method.

The compiler knows this. So, in this particular case, it will probably optimize it and “inline...

CONTINUE READING
83
Tech Concepts
36
Programming languages
73
Tech Tools
Icon Unlimited access to the largest independent learning library in tech of over 8,000 expert-authored tech books and videos.
Icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Icon 50+ new titles added per month and exclusive early access to books as they are being written.
Systems Programming with C# and .NET
notes
bookmark Notes and Bookmarks search Search in title playlist Add to playlist download Download options font-size Font size

Change the font size

margin-width Margin width

Change margin width

day-mode Day/Sepia/Night Modes

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Confirmation

Modal Close icon
claim successful

Buy this book with your credits?

Modal Close icon
Are you sure you want to buy this book with one of your credits?
Close
YES, BUY

Submit Your Feedback

Modal Close icon
Modal Close icon
Modal Close icon