libitm: Don't execute memtransfer/memset if size isn't larger than zero.
libitm/ * dispatch.h (CREATE_DISPATCH_METHODS_MEM): Don't execute memtransfer/memset if size isn't larger than zero. From-SVN: r184941
This commit is contained in:
parent
034209bc2f
commit
d28b0b0861
@ -1,3 +1,8 @@
|
||||
2012-03-05 Torvald Riegel <triegel@redhat.com>
|
||||
|
||||
* dispatch.h (CREATE_DISPATCH_METHODS_MEM): Don't execute
|
||||
memtransfer/memset if size isn't larger than zero.
|
||||
|
||||
2012-03-02 Torvald Riegel <triegel@redhat.com>
|
||||
|
||||
* libitm.texi: Link to specification and add a usage example.
|
||||
|
@ -102,11 +102,13 @@
|
||||
virtual void memtransfer(void *dst, const void* src, size_t size, \
|
||||
bool may_overlap, ls_modifier dst_mod, ls_modifier src_mod) \
|
||||
{ \
|
||||
memtransfer_static(dst, src, size, may_overlap, dst_mod, src_mod); \
|
||||
if (size > 0) \
|
||||
memtransfer_static(dst, src, size, may_overlap, dst_mod, src_mod); \
|
||||
} \
|
||||
virtual void memset(void *dst, int c, size_t size, ls_modifier mod) \
|
||||
{ \
|
||||
memset_static(dst, c, size, mod); \
|
||||
if (size > 0) \
|
||||
memset_static(dst, c, size, mod); \
|
||||
}
|
||||
|
||||
#define CREATE_DISPATCH_METHODS_MEM_PV() \
|
||||
|
Loading…
Reference in New Issue
Block a user