From: Rodrigo Kumpera Date: Thu, 11 May 2017 22:52:09 +0000 (-0700) Subject: [jit] Fix large const memcpy/memset when when the intrins pass is disabled. X-Git-Url: http://wien.tomnetworks.com/gitweb/?a=commitdiff_plain;h=28a16d28a00646d757eb37f94948b3294e76626b;p=mono.git [jit] Fix large const memcpy/memset when when the intrins pass is disabled. --- diff --git a/mono/mini/memory-access.c b/mono/mini/memory-access.c index 34edb52b338..86e1cb43867 100644 --- a/mono/mini/memory-access.c +++ b/mono/mini/memory-access.c @@ -181,7 +181,7 @@ mini_emit_memcpy_internal (MonoCompile *cfg, MonoInst *dest, MonoInst *src, Mono /* FIXME: Optimize the case when src/dest is OP_LDADDR */ /* We can't do copies at a smaller granule than the provided alignment */ - if (size_ins || ((size / align > MAX_INLINE_COPIES) && !(cfg->opt & MONO_OPT_INTRINS))) { + if (size_ins || (size / align > MAX_INLINE_COPIES) || !(cfg->opt & MONO_OPT_INTRINS)) { MonoInst *iargs [3]; iargs [0] = dest; iargs [1] = src; @@ -201,7 +201,7 @@ mini_emit_memset_internal (MonoCompile *cfg, MonoInst *dest, MonoInst *value_ins /* FIXME: Optimize the case when dest is OP_LDADDR */ /* We can't do copies at a smaller granule than the provided alignment */ - if (value_ins || size_ins || value != 0 || ((size / align > MAX_INLINE_COPIES) && !(cfg->opt & MONO_OPT_INTRINS))) { + if (value_ins || size_ins || value != 0 || (size / align > MAX_INLINE_COPIES) || !(cfg->opt & MONO_OPT_INTRINS)) { MonoInst *iargs [3]; iargs [0] = dest;