Hi all,
I am working on SH4 architecture. I observed one strange thing. Each time i build my kernel image (uImage) the last 10% of the uImage content is changing. I compared uImages using diff command and with Beyond Compare tool, which i did using binary as well as rule based comparison with time stamp comparison disabled. I observed that every time when i build the kernel image the lower 10% of the uImage differ from the previously build uImage (build with in 20 min before the last one). Can any one help me to know the reason behind this behavior? I want to know more about the format of uImage and what exactly the lower 10% contains? i searched in various sites and referred the documentation of U-boot. But i dint get the reason for this behavior. I did the same comparison with vmlinux and vmlinux.bin and i observed that each time i build these vmlinux and vimlinux.bin they differ from the previous images (which i build 20 min before the last one ) by a max of 10 lines.
When i opened two vimlinux images (which i build with in a time gap of 20 min)using the readelf command. I observed that there is no difference at all in the readelf output.
I tried the same thing with i386 kernel, here also i observed that each time i build the kernel , vmlinux and bzImage are different compared to the previously build images. I hope some time related things are happening while building the kernel. Can any one explain me why this is happening?
Please help me to understand this.
Thanks,
Santhosh
The kernel image includes
The kernel image includes the timestamp it was built on for each build. I can't think of anything else that would be guaranteed to change -- the tools you're using are probably just seeing that and freaking out a bit. Turning off timestamp change reporting probably has no effect since it would have no way of knowing which particular byte ranges represent numeric timestamps.
compressed
the vmlinux kernel images are uncompressed, but vmlinuz (alias bzImage etc.) images are compressed on disk (thus the 'z'). the first thing the kernel image does when loaded is uncompressing itself (thus the corresponding boot message). after the first difference in the original compressed files differ.
Thank you for your reply. I
Thank you for your reply. I thought that it might be because of some time stamp. But when i compared the vmlinux, the differences are not in the header or in the end of the file. In vmlinux , there is only max of lines differ and that to in the middle of the code, but not in continuous 10 lines.. but bzImage and in uImage always the lower portions are different.
FYI
Hi Ho!
This might help:
(Different object code generated each time file is compiled) http://gcc.gnu.org/ml/gcc-help/2008-09/msg00283.html
Best regards,
Eus