On 01/21/2016 01:25 PM, Mark Morgan Lloyd wrote:
I didn't say anything wouldn't work.
Sorry. I took "issue" for a potential problem
Copying data tends to introduce a significant performance hit, which is why many OSes try to avoid it by passing pointers. The typical result of passing pointers is to introduce the possibility of buffer overflows, because the lower-level (and more privileged) code doesn't (or can't) apply application-specific tests.
Right you are. That i why the second method - if carefully done - would create less overhead.
Nonetheless with any transfer to the main thread, a new buffer needs to be allocated.
-Michael -- _______________________________________________ Lazarus mailing list [email protected] http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
