|
|
View previous topic :: View next topic |
Author |
Message |
zio_pecos
Joined: 24 Oct 2004 Posts: 21 Location: italy
|
pcw instruction |
Posted: Wed Nov 17, 2004 2:46 am |
|
|
i need to know differences between c and pcw instruction
in terms of
bit lenght
potentiality
do you know a web link or can you tell me something?
thank you |
|
|
Ttelmah Guest
|
Re: pcw instruction |
Posted: Wed Nov 17, 2004 3:11 am |
|
|
zio_pecos wrote: | i need to know differences between c and pcw instruction
in terms of
bit lenght
potentiality
do you know a web link or can you tell me something?
thank you |
PCW, is 'C'. It is in some ways closer to the original K&R definitions than most modern compilers (which support an extended 'set' of syntax and instructions in 'ANSI C'). 99% of the original C instructions are supported. 'Bit length'?. 'C' has no effect on the ability of the processor (CCS have here followed the original K&R defintions, where the definition of an 'integer', is that it should be the 'native' type for the processor). Hence the CCS C, uses int to represent an 8bit value, but then offers a int16, and an int32. 'Potentiality', just about anything that can be written in normal C, can be written into the CCS, but you then have the limitations of the chip itself. For example, 're-entrancy', cannot be supported without some form of variable 'stack', which the chips do not support. Code size, and the number of variables, are dependant on the chip involved. CCS, has some (significant) weaknesses, when complex constructions are used (structures, containing further structures/unions, going to a significant 'depth', seem very unreliable). However these are beyond anything illustrated in the original K&R book. Allmost every example in K&R, can be directly compiled and run, except for a couple using re-entrancy.
Beyond 'C', the CCS compiler adds quite a lot of 'extras', for direct I/O (the #bit, and #byte operators etc.).
Best Wishes |
|
|
Guest
|
|
Posted: Wed Nov 17, 2004 10:46 am |
|
|
thank you...
i've posted this question because a friend of mine had found on the net a document that illustrate with high precision a comparing between pcw and C
all that you told me is what i was looking for
thank you
i there is anything else post it!!!!
|
|
|
Ttelmah Guest
|
|
Posted: Wed Nov 17, 2004 11:02 am |
|
|
Anonymous wrote: | thank you...
i've posted this question because a friend of mine had found on the net a document that illustrate with high precision a comparing between pcw and C
all that you told me is what i was looking for
thank you
i there is anything else post it!!!!
|
I think the key here, will be 'ANSI C'. In ANSI C, the default 'integer', is a 16bit type. In the original C, the default varied with the processor, and this is retained in CCS C.
Best Wishes |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|