- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi all: I'm working with IPP from years but I have a doubt about using ofippsCopy_8u. I hope someone can solve me one for all :)
If I allocate memory with a standard "malloc" or "new" operator (so without usingippsMalloc): is it safe to useippsCopy_8u on it? or due to memory not aligned the copy could overflow my buffer?
I mean:
char* p1=new char[100];
char* p2=new char[100];
ippsCopy_8u(p1,p2,100); -> is it safe with any size on every allocations?
furthermore: if I useippsCopy_8u on a memory allocated with "new" or with a memory allocated with "ippsMalloc", can I obtain different performance?
1 Solution
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
it is safe to call IPP functions on not aligned data. Of course you may expect different performance in this case simple because modern processors access data by aligned addressed more efficiently.
Regards,
Vladimir
it is safe to call IPP functions on not aligned data. Of course you may expect different performance in this case simple because modern processors access data by aligned addressed more efficiently.
Regards,
Vladimir
Link Copied
3 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
it is safe to call IPP functions on not aligned data. Of course you may expect different performance in this case simple because modern processors access data by aligned addressed more efficiently.
Regards,
Vladimir
it is safe to call IPP functions on not aligned data. Of course you may expect different performance in this case simple because modern processors access data by aligned addressed more efficiently.
Regards,
Vladimir
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ok thank you for solving my long time doubt :)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You are welcome.
FYI, in IPP test suite we have a special class of tests to check that functions work with not aligned data.
Regards,
Vladimir
FYI, in IPP test suite we have a special class of tests to check that functions work with not aligned data.
Regards,
Vladimir
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page