I have written one kernel module, I want to generate assembly code i.e *.s
file.
Till now I am able to generate .s
file from object file by using objdump
but it's not providing me proper assembly code. Can anyone please help me with this.
I have written one kernel module, I want to generate assembly code i.e *.s
file.
Till now I am able to generate .s
file from object file by using objdump
but it's not providing me proper assembly code. Can anyone please help me with this.
You have to use -S
option for generating an assembly code, also I would suggest to disable any optimization with -O0
option (if you need it) , if you want to see optimized assmbly code, just add -S
More info about gcc options you may find here