summaryrefslogtreecommitdiff
path: root/src/alloc.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/alloc.c')
-rw-r--r--src/alloc.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/alloc.c b/src/alloc.c
index d758ca18a7b..bf0456c6862 100644
--- a/src/alloc.c
+++ b/src/alloc.c
@@ -3175,10 +3175,9 @@ allocate_pseudovector (int memlen, int lisplen,
eassert (lisplen <= (1 << PSEUDOVECTOR_SIZE_BITS) - 1);
/* Only the first LISPLEN slots will be traced normally by the GC.
- If Qnil is nonzero, clear the non-Lisp data separately. */
+ Since Qnil == 0, we can memset Lisp and non-Lisp data at one go. */
+ verify (NIL_IS_ZERO);
memsetnil (v->contents, zerolen);
- if (NIL_IS_NONZERO)
- memset (v->contents + lisplen, 0, (zerolen - lisplen) * word_size);
XSETPVECTYPESIZE (v, tag, lisplen, memlen - lisplen);
return v;