Skip to content

Learn GNU Assembler (as or gas) this book is great and I'm going to update it to enhance it.

License

Notifications You must be signed in to change notification settings

airvzxf/programming-ground-up-and-under-hood

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Programming from the ground up |
Programming under hood
Updated by AirvZxf

About this project.

I try to learn the GNU Assembler (as or gas) and I didn't found many resources but this book is great.

This is a 60% of the WIP (work in progress) for the project Programming from the ground up.

Goals:

  • Programming from the ground up.
    • Convert the original DocBook to a Markdown then with pandoc convert it to ePUB, MOBI and PDF.
    • Improve and update the sections where I am missing.
    • Try to fix the bugs and support tickets, since 2004 is not updated this book.
  • Programming under hood.
    • Convert the original LaTeX to a Markdown then with pandoc then convert it to ePUB, MOBI and PDF.
  • Final version.
    • Create a version for x64 architecture.
  • Create my own book based in the experience that I gained in this project. It should will in a new GitHub repository.

You're able to find my documents about assembly in my GitHub repository airvzxf/assembly also I was working in some assembler scripts that I wrote based on the exercises of this book. It contains a Linux shell script to make all the binaries straightforward.

Motivations.

  • I believe that Linux is the future, I dream with a world when everyone is using Linux in our laptops, desktop computers, and all the video game companies make perfect games for Linux.
  • I was researching about GNU Assembler (“as” or “gas”) but unfortunately, there are not many resources, these resources talk about the most popular as “NASM” and “FASM”.
  • Why NOT focus on “NASM” or “FASM”? I started with “NASM” then I saw a few years ago the active development stopped. I researched about “FASM” and looks like it's awesome but then I discovered some curious detail. These assemblers can compile in many architectures and it is powerful but trying to be very compatible they spend a lot of effort to create the most generic binary source possible (1). At this moment I start to consider the possibility to use the pure Linux assembler because for me the idea to use a multi-architectural assembler is only marketing. I have been software developer over 14 years and I never created a multi-architecture system neither in my personal projects. Why am I living in a utopia? Wanted a tool to convert to other architectures, if I always create programs for Linux and very rarely for Windows. In these cases I usually use Python or Java. Note: This is my personal point of view, haters please hate more.
  • Why use Assembler rather other languages programs? The benchmarks that I did demonstrate that Assembler is the most powerful even tan C which is the top language. My benchmarks and the C benchmarks.
  • Why update this book? This book is one of the best that I found but it has many areas of opportunity. I read until the chapter 3 and I had three doubts in the final exercises but there are no answers. The book said that we saw this subject and I reviewed all the chapters and it didn't.
  • Deep thanks to the men and companies who inspired me to be better and thanks to the Open Source: Linus Torvalds, Richard Stallman, Linux, GNU, GitHub.

First steps: Programming from the ground up.

  • Download the original source code.
  • Figured out how to compile the source code.
    • It's not easy and needs to install some packages also I couldn't compile the book. Other reason is that the DSSSL is an old technology.
  • Make decisions if keeps this format or use other tools/format.
    • Use pandoc (official project) to convert the original DocBook to Markdown format.
      • Fix all the conversions failures.
        • Footnotes needs to create a new numeration.
        • Internal broken links for references.
        • Styles and formats.
        • Create a ToC (Table of contents).
      • Export to the final version to ePUB.
      • Export to the final version to MOBI for Kindle.
  • Start with the TO-DO's file.

About the original books.

Important notes.

  • This book is under the License: “GNU Free Documentation License”. I added the license “GNU General Public License v3.0” in this repository as a reference but keep the original license as the unique and valid.

Original source: Programming from the ground up.

Original source: Programming under the hood.

Footnotes:

  • 1: FASM: Design Principles, or Why FASM Is Different sections “4) Resolving The Code” and “5) Complex Solutions With Simple Features”. In general this document provides an overview of the complexity behind trying to do an assembler multi-architecture.