View previous topic :: View next topic |
Author |
Message |
agrj
Joined: 26 Sep 2003 Posts: 48
|
compiler upgrade - a silly question |
Posted: Wed Dec 08, 2004 12:09 pm |
|
|
Hi All,
if I upgrade my compiler, the same code should generate the same check sum for both versions?
thanks
Aryldo |
|
|
Mark
Joined: 07 Sep 2003 Posts: 2838 Location: Atlanta, GA
|
|
Posted: Wed Dec 08, 2004 12:12 pm |
|
|
Not always. The compiler might change how it generates code (big fixes, optimizations, etc..). |
|
|
agrj
Joined: 26 Sep 2003 Posts: 48
|
|
Posted: Wed Dec 08, 2004 12:38 pm |
|
|
So, how can I be sure that the code generated by the new version is OK? I have to test it all again?
thanks
Aryldo |
|
|
Mark
Joined: 07 Sep 2003 Posts: 2838 Location: Atlanta, GA
|
|
Posted: Wed Dec 08, 2004 12:49 pm |
|
|
Exactly! Why are you upgrading? If the code you have is stable, then store that compiler version with the source. You can always rebuild with that compiler version and get the same results. |
|
|
agrj
Joined: 26 Sep 2003 Posts: 48
|
|
Posted: Wed Dec 08, 2004 12:59 pm |
|
|
That�s exactly what I�m doing. I was just wonder when I could belive that the newer version would be good to be used!!
I�m using the 3.204 version, and everything looks fine, but how knows after all!!
thanks
Aryldo |
|
|
Will Reeve
Joined: 30 Oct 2003 Posts: 209 Location: Norfolk, England
|
|
Posted: Fri Dec 10, 2004 4:33 am |
|
|
I allways make sure I note the compiler version in the source code and do stick with a version when the product is released into the real world.
However I allways feel I should be using the latest version, must be human nature, or just me!
Will |
|
|
SherpaDoug
Joined: 07 Sep 2003 Posts: 1640 Location: Cape Cod Mass USA
|
|
Posted: Fri Dec 10, 2004 7:55 am |
|
|
"Better the devil you know than the devil you don't."
I am still using version 3.104 because it does what I need. When I need something this version doesn't have I will upgrade. But I will archive 3.104 with the source code of my current projects.
The PIC 10F chips are likely to cause the next upgrade for me. _________________ The search for better is endless. Instead simply find very good and get the job done. |
|
|
Humberto
Joined: 08 Sep 2003 Posts: 1215 Location: Buenos Aires, La Reina del Plata
|
|
Posted: Fri Dec 10, 2004 8:20 am |
|
|
Quote: |
I am still using version 3.104 because it does what I need
|
Hi SherpaDoug,
Just a curiously question, 3.104 is a typo for 3.204 or is the
actual version that you are using ?
Humberto |
|
|
SherpaDoug
Joined: 07 Sep 2003 Posts: 1640 Location: Cape Cod Mass USA
|
|
Posted: Fri Dec 10, 2004 9:20 am |
|
|
Nope. It is really 3.104. I ordered it to replace my 2.7xx shortly after 3.xxx came out and that is what shipped. I then upgraded but lost the upgrade to a disk failure and didn't do any C work for few months. By the time I needed C again my upgrade period had ended so I am using 3.104 off the CD ROM. My programs are pretty simple and it does what I need. I haven't seen any fatal bugs yet. _________________ The search for better is endless. Instead simply find very good and get the job done. |
|
|
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Fri Dec 10, 2004 1:13 pm |
|
|
Quote: | So, how can I be sure that the code generated by the new version is OK? |
I don't upgrade very often. I'm still using vs. 3.188 for both compilers,
even though I have the maintenance subscription for PCM.
If you a version that's working, but you want to upgrade anyway,
then you should compile your program with both versions and do
a side-by-side comparison of the .LST files in MPLAB.
Use the Window menu and select "Tile Vertically" to do this.
(First close all windows except for those two .LST files).
It takes a little while to scan the two .LST files, but if you're really
worried about the safety of the upgrade, then you have to do it.
If you notice a difference in the files in a few routines, you should
closely examine those places and confirm that the new version's
code is OK.
This method won't catch every possible problem because the new
version might have a problem with some C syntax that you're not
currently using, but at least you can convince yourself that your
existing code will work OK. |
|
|
|