|
Ummm... it is my understanding (perhaps flawed? Barbara? Simon? Bueller?)
that "procedures" like _memcpy are actually interfaces to the MI
instruction.
I would suggest that the MI memcpy operation code (and yes, there is one -
see
http://publib.boulder.ibm.com/iseries/v5r1/ic2924/tstudio/tech_ref/mi/MEMCPY
.htm) similarity to the C function is an engineered "coincidence."
I would also suggest that since IBM have opted to provide such interfaces
into the lower levels of the system, they won't take those interfaces away.
Finally, I see occasional suggestion from Barbara and others to use the MI
built-ins (see http://archive.midrange.com/rpg400-l//200301/msg00433.html as
an example), so I say that with some confidence.
As Simon tried to point out, the MEMCPY.htm link I provided above warns
about overlapping fields and undefined results, so I won't be trying the MI
after all.
But I still would like to know why Simon said that about it being more
likely the compiler than the MI. Is _memcpy() an interface to MI, and does
the ILE RPG compiler influence its actions?
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.