uVision1 & uVision2 (keil) c51 differences

Hi, I have inhereted an old project from the late 90's that was built using keils uVision1 compiler (c51) for Dallas 87C520. I have created a new project to compile and link the code in uVision2.

I get a lot of these messages

*** WARNING L13: RECURSIVE CALL TO SEGMENT SEGMENT: ?CO?XXXX CALLER: ?PR?YYYY?XXXX

which according to the c51 primer book seems to be caused by jump tables of functions, which are in the code.

Wondering what to do. I think the project compiled and linked ok with uVision1 (don't have the application anymore). So is there really that big a difference between the compilers?

What can I do to cure these warnings? It almost seems like a backwards step if the compiler can't deal with this anymore.

Eventually I get an error since I have too many warnings.

Any thoughts?

Reply to
Rob
Loading thread data ...

Function pointers in C51 are indeed something that has to be used with great care. Unless your project is so small that you can afford turning off overlay analysis in the linker, it wreaks havoc with fundamental aspects of how C51 works, and needs special manual attention to be usable.

You'll have to recreate some detailed settings in the IDE --- if you didn't import your uV1 project into uV2, but tried created a new one instead, it's time to rethink that decision. Also see the Keil website for appnotes that explain this in more details.

--
Hans-Bernhard Broeker (broeker@physik.rwth-aachen.de)
Even if all the snow were burnt, ashes would remain.
Reply to
Hans-Bernhard Broeker

Is your code making callto to other segments from interrupts?

Reply to
Jona Vark

Is there a compiler option to automatically make all functions re-entrant? In the compiler I use (Hi-tech C51) this can be done by specifying the large memory model.

--
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/
Reply to
Ross Marchant

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.