J
Jiri Baum
This is a kind of strength-reduction, and modern compilers will do it for you automatically. Indeed, in C, arrays and pointers are so similar that there is little difference to begin with.
The only way this would make any difference would be if you accidentally stumbled onto something for which the compiler has an efficient idiom. Which may be worth a try, but it sounds unlikely.
BTW, why would it involve overwriting one of the arrays? There's no reason why you can't use three matrices with pointers:
*c++ = *a++ + *b++
nor why you couldn't overwrite one of the arrays in array notation:
a += b
Jiri
--
Jiri Baum <[email protected]> http://www.csse.monash.edu.au/~jirib
MAT LinuxPLC project --- http://mat.sf.net --- Machine Automation Tools
The only way this would make any difference would be if you accidentally stumbled onto something for which the compiler has an efficient idiom. Which may be worth a try, but it sounds unlikely.
BTW, why would it involve overwriting one of the arrays? There's no reason why you can't use three matrices with pointers:
*c++ = *a++ + *b++
nor why you couldn't overwrite one of the arrays in array notation:
a += b
Jiri
--
Jiri Baum <[email protected]> http://www.csse.monash.edu.au/~jirib
MAT LinuxPLC project --- http://mat.sf.net --- Machine Automation Tools