Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Novice
1,254 Views

Compiler for Compiling only in Assembly code?

Jump to solution

I want to program my Galileo Board with assembly; this is known as bare metal programming.

I have read the two discussions regarding this topic in this forum.

My question is this: can I program only in assembly by using Intel's C++ compiler?

I know you can use the __asm keyword, but this applies for "in-line" assembly. I would like to program the whole code in assembly. Is this possible with this compiler or is there another compiler more suitable for this?

Thank you in advance for any information and help.

Best regards.

0 Kudos

Accepted Solutions
Valued Contributor I
50 Views

Where to start.... Let me start by copying Wikipedia:

"The GNU Assembler, commonly known as gas or simply as, its executable name, is the http://en.wikipedia.org/wiki/Assembler_(computer_programming) assembler used by the http://en.wikipedia.org/wiki/GNU_Project GNU Project. It is the default http://en.wikipedia.org/wiki/Back-end back-end of http://en.wikipedia.org/wiki/GNU_Compiler_Collection GCC. It is used to assemble the http://en.wikipedia.org/wiki/GNU_operating_system GNU operating system and the http://en.wikipedia.org/wiki/Linux_kernel Linux kernel, and various other software. It is a part of the http://en.wikipedia.org/wiki/GNU_Binutils GNU Binutils package.

The GAS http://en.wikipedia.org/wiki/Executable executable is named http://en.wikipedia.org/wiki/As_(Unix) as, the standard name for a http://en.wikipedia.org/wiki/Unix Unix assembler. GAS is http://en.wikipedia.org/wiki/Cross-platform cross-platform, and both runs on and assembles for a number of different http://en.wikipedia.org/wiki/Computer_architecture computer architectures. Released under the http://en.wikipedia.org/wiki/GNU_General_Public_License GNU General Public License v3, GAS is http://en.wikipedia.org/wiki/Free_software free software."

If you are hung up on Intel syntax, there is even a .intel directive.

If your Linux build includes build tools (and why wouldn't it), you already have all of this.

Check out the WikiPedia article for a sample assembler program.

View solution in original post

2 Replies
Valued Contributor I
51 Views

Where to start.... Let me start by copying Wikipedia:

"The GNU Assembler, commonly known as gas or simply as, its executable name, is the http://en.wikipedia.org/wiki/Assembler_(computer_programming) assembler used by the http://en.wikipedia.org/wiki/GNU_Project GNU Project. It is the default http://en.wikipedia.org/wiki/Back-end back-end of http://en.wikipedia.org/wiki/GNU_Compiler_Collection GCC. It is used to assemble the http://en.wikipedia.org/wiki/GNU_operating_system GNU operating system and the http://en.wikipedia.org/wiki/Linux_kernel Linux kernel, and various other software. It is a part of the http://en.wikipedia.org/wiki/GNU_Binutils GNU Binutils package.

The GAS http://en.wikipedia.org/wiki/Executable executable is named http://en.wikipedia.org/wiki/As_(Unix) as, the standard name for a http://en.wikipedia.org/wiki/Unix Unix assembler. GAS is http://en.wikipedia.org/wiki/Cross-platform cross-platform, and both runs on and assembles for a number of different http://en.wikipedia.org/wiki/Computer_architecture computer architectures. Released under the http://en.wikipedia.org/wiki/GNU_General_Public_License GNU General Public License v3, GAS is http://en.wikipedia.org/wiki/Free_software free software."

If you are hung up on Intel syntax, there is even a .intel directive.

If your Linux build includes build tools (and why wouldn't it), you already have all of this.

Check out the WikiPedia article for a sample assembler program.

View solution in original post

Novice
50 Views

Thanks, I will look at the info. It looks like what I was looking for.

I have to admit, I looked all over the internet but I didn't find the answer I was looking for. I guess I am used to specific Assembly tools for specific manufacturers; my background is in embedded systems and I never considered Linux. I like to take full control of my devices without OS interference.

So much to learn! I love this.