Skip to content

Commit 31375c5

Browse files
committed
Merge branch 'PHP-7.3'
2 parents acd3bae + 325a113 commit 31375c5

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

ext/opcache/Optimizer/compact_literals.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -804,9 +804,9 @@ void zend_optimizer_compact_literals(zend_op_array *op_array, zend_optimizer_ctx
804804
zval *val = &op_array->literals[opline->op2.constant];
805805

806806
if (Z_TYPE_P(val) == IS_CONSTANT_AST) {
807-
uint32_t slot = ZEND_MM_ALIGNED_SIZE_EX(op_array->cache_size, 8);
808-
809-
Z_CACHE_SLOT_P(val) = slot;
807+
/* Ensure zval is aligned to 8 bytes */
808+
op_array->cache_size = ZEND_MM_ALIGNED_SIZE_EX(op_array->cache_size, 8);
809+
Z_CACHE_SLOT_P(val) = op_array->cache_size;
810810
op_array->cache_size += sizeof(zval);
811811
}
812812
} else if (opline->opcode != ZEND_RECV) {

0 commit comments

Comments
 (0)