]> git.kaiwu.me - njs.git/commitdiff
Removing MSAN unpoison workarounds for clang-9 and below.
authorDmitry Volyntsev <xeioex@nginx.com>
Wed, 12 Jan 2022 17:58:18 +0000 (17:58 +0000)
committerDmitry Volyntsev <xeioex@nginx.com>
Wed, 12 Jan 2022 17:58:18 +0000 (17:58 +0000)
MSAN unpoison workaround was introduced in 13dbdff9b76f (0.3.9) for a
false-positive bug in clang-9 and below.

Also, after 80d95b2881f6 (0.4.1) the bug is not triggered anymore.

src/njs_value.h

index 62da8136e010e237602a0453e2cba4760295b849..5dfb8e9da412acf0c6df6d9166af530f8561ece6 100644 (file)
@@ -1028,8 +1028,6 @@ njs_set_object_value(njs_value_t *value, njs_object_value_t *object_value)
         (pq)->lhq.key.length = 0;                                             \
         (pq)->lhq.key.start = NULL;                                           \
         (pq)->lhq.value = NULL;                                               \
-        /* FIXME: False-positive in MSAN?. */                                 \
-        njs_msan_unpoison(&(pq)->key, sizeof(njs_value_t));                   \
         (pq)->own_whiteout = NULL;                                            \
         (pq)->query = _query;                                                 \
         (pq)->shared = 0;                                                     \
@@ -1085,9 +1083,6 @@ njs_value_property_i64(njs_vm_t *vm, njs_value_t *value, int64_t index,
     njs_int_t    ret;
     njs_value_t  key;
 
-    /* FIXME: False-positive in MSAN?. */
-    njs_msan_unpoison(&key, sizeof(njs_value_t));
-
     ret = njs_int64_to_string(vm, &key, index);
     if (njs_slow_path(ret != NJS_OK)) {
         return ret;
@@ -1104,9 +1099,6 @@ njs_value_property_i64_set(njs_vm_t *vm, njs_value_t *value, int64_t index,
     njs_int_t    ret;
     njs_value_t  key;
 
-    /* FIXME: False-positive in MSAN?. */
-    njs_msan_unpoison(&key, sizeof(njs_value_t));
-
     ret = njs_int64_to_string(vm, &key, index);
     if (njs_slow_path(ret != NJS_OK)) {
         return ret;
@@ -1123,9 +1115,6 @@ njs_value_property_i64_delete(njs_vm_t *vm, njs_value_t *value, int64_t index,
     njs_int_t    ret;
     njs_value_t  key;
 
-    /* FIXME: False-positive in MSAN?. */
-    njs_msan_unpoison(&key, sizeof(njs_value_t));
-
     ret = njs_int64_to_string(vm, &key, index);
     if (njs_slow_path(ret != NJS_OK)) {
         return ret;