Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 01-14-2011, 07:31 AM   #1
LQ Newbie
Registered: May 2009
Posts: 2

Rep: Reputation: 0
How to check/understand the output of assembly file (.s) file?.

Hi All,

I have a small doubt regarding Assembly file compilation.
I have two .s files. When I compile two .s files I am getting corresponding .o files.
But when I compare the both .o files with diff command, it is resulting that two files are differing.

How could/ what are commands we should use to understand the difference between two .o file's output.

Please help me.

Old 01-14-2011, 08:48 AM   #2
LQ 5k Club
Registered: Sep 2009
Posts: 6,443
Blog Entries: 3

Rep: Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721
What makes you think that two different assembly files would produce the same object file when assembled?

Or am I misunderstanding you?

Last edited by MTK358; 01-14-2011 at 08:56 AM. Reason: I wrote "compiled" instead of "assembled"
Old 01-14-2011, 08:52 AM   #3
Senior Member
Registered: Mar 2008
Location: Cyberspace
Distribution: Dynebolic, Ubuntu 10.10
Posts: 1,340

Rep: Reputation: 62
... and it's not "compiled" by the way, it's "assembled".
Old 01-15-2011, 10:03 PM   #4
LQ Newbie
Registered: May 2009
Posts: 2

Original Poster
Rep: Reputation: 0
Dear MTK358,

I will put my qns like this.
I have first.s file in my project.

In my configuration file, I made some changes such that it wont effect the existing functionality of the code (I introduced few new macros). I recompiled the code. Now I have my compiled set of files before changes and compiled set of files after changes.

My requirement is these two binaries should match.

But few binaries are differing including these .s file object files.

I am trying to analyze, why these two files are differing?.

Old 01-16-2011, 04:10 AM   #5
Senior Member
Registered: Mar 2008
Location: Cyberspace
Distribution: Dynebolic, Ubuntu 10.10
Posts: 1,340

Rep: Reputation: 62
eh? i don't get it. what do you mean you put new macros in a CONF file? they go in the ASM file itself!
post your code.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
data from input file to be taken and send to output file grishu Linux - Newbie 18 08-03-2010 08:02 AM
Moved file partitions, File system check failed on Fedora, Windows will not boot LinkSlayer64 Linux - Newbie 7 12-17-2009 02:18 AM
GPG - encode file while manipulating output file name itmozart Linux - Newbie 2 10-03-2009 12:28 PM
How to write crontab to check file size and all file in a directory? modpriest Linux - Newbie 1 02-14-2008 06:48 AM
why when redirecting output to a file any file extension seems to be fine? dr_zayus69 Linux - General 1 05-21-2005 04:09 AM

All times are GMT -5. The time now is 02:08 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration