# FW: Help needed in benchmarking memory patch

- Thread: https://externals.io/message/24290
- Original archive: https://news-web.php.net/php.internals/24290
- Started by Andi Gutmans on 2006-07-08T03:37:35+00:00
- Messages: 3
- Reply by email to internals@lists.php.net
- More for agents: search with https://externals.io/search.md?q={query} · JSON API at https://externals.io/api · documentation at https://externals.io/llms.txt

---

## #24290 — Andi Gutmans — 2006-07-08T03:37:35+00:00

URL: https://externals.io/message/24290#24290

Sending 3rd time this time without the attachment.
You can get the diff at http://gutmans.org/alloc.zip 


-----Original Message-----
From: Andi Gutmans [mailto:andi@zend.com] 
Sent: Thursday, July 06, 2006 11:06 PM
To: 'internals@lists.php.net'
Subject: Help needed in benchmarking memory patch

Hi all,

Attached is a patch we've been working on to improve the memory management
of PHP. This patch's main advantage is reducing the memory footprint of PHP,
and therefore allowing it to scale better. Although at low concurrencies the
change seems to be negligble, while testing at higher concurrencies we saw
significant improvement with this patch, mainly due to lower memory usage.

We would very much appreciate if people here tested this patch and send in
their results. It would help us understand if others are getting consistent
results with ours, and also see whether there are any additional
improvements we should make.

This patch should apply cleanly to the PHP 5.2 CVS tree. There's not much
tuning that needs to be done. It uses malloc() to allocate large memory
blocks. You can control the size of these blocks by setting the
ZEND_MM_SEG_SIZE environment variable before starting Apache/PHP. You may
use K or M to play around with the block size. The default we are using is
256KB which seems to be a good balance.

Any feedback would be appreciated!

Andi

---

## #24303 — Andi Gutmans — 2006-07-08T15:20:32+00:00

URL: https://externals.io/message/24290#24303 · In reply to: #24290

Anyone who'd like to try benchmark this, please drop me an email. We can
also discuss how best to test.

Thx.

Andi 

> -----Original Message-----
> From: Andi Gutmans [mailto:andi@zend.com] 
> Sent: Friday, July 07, 2006 8:38 PM
> To: internals@lists.php.net
> Subject: [PHP-DEV] FW: Help needed in benchmarking memory patch
> 
> Sending 3rd time this time without the attachment.
> You can get the diff at http://gutmans.org/alloc.zip 
> 
> 
> -----Original Message-----
> From: Andi Gutmans [mailto:andi@zend.com]
> Sent: Thursday, July 06, 2006 11:06 PM
> To: 'internals@lists.php.net'
> Subject: Help needed in benchmarking memory patch
> 
> Hi all,
> 
> Attached is a patch we've been working on to improve the 
> memory management of PHP. This patch's main advantage is 
> reducing the memory footprint of PHP, and therefore allowing 
> it to scale better. Although at low concurrencies the change 
> seems to be negligble, while testing at higher concurrencies 
> we saw significant improvement with this patch, mainly due to 
> lower memory usage.
> 
> We would very much appreciate if people here tested this 
> patch and send in their results. It would help us understand 
> if others are getting consistent results with ours, and also 
> see whether there are any additional improvements we should make.
> 
> This patch should apply cleanly to the PHP 5.2 CVS tree. 
> There's not much tuning that needs to be done. It uses 
> malloc() to allocate large memory blocks. You can control the 
> size of these blocks by setting the ZEND_MM_SEG_SIZE 
> environment variable before starting Apache/PHP. You may use 
> K or M to play around with the block size. The default we are 
> using is 256KB which seems to be a good balance.
> 
> Any feedback would be appreciated!
> 
> Andi
> 
> --
>  To 
> unsubscribe, visit: http://www.php.net/unsub.php

---

## #24308 — Andi Gutmans — 2006-07-10T15:57:35+00:00

URL: https://externals.io/message/24290#24308 · In reply to: #24290

No help??? Come on guys. I'm sure some of you can spare a few idle cycles :)


> -----Original Message-----
> From: Andi Gutmans [mailto:andi@zend.com] 
> Sent: Friday, July 07, 2006 8:38 PM
> To: internals@lists.php.net
> Subject: [PHP-DEV] FW: Help needed in benchmarking memory patch
> 
> Sending 3rd time this time without the attachment.
> You can get the diff at http://gutmans.org/alloc.zip 
> 
> 
> -----Original Message-----
> From: Andi Gutmans [mailto:andi@zend.com]
> Sent: Thursday, July 06, 2006 11:06 PM
> To: 'internals@lists.php.net'
> Subject: Help needed in benchmarking memory patch
> 
> Hi all,
> 
> Attached is a patch we've been working on to improve the 
> memory management of PHP. This patch's main advantage is 
> reducing the memory footprint of PHP, and therefore allowing 
> it to scale better. Although at low concurrencies the change 
> seems to be negligble, while testing at higher concurrencies 
> we saw significant improvement with this patch, mainly due to 
> lower memory usage.
> 
> We would very much appreciate if people here tested this 
> patch and send in their results. It would help us understand 
> if others are getting consistent results with ours, and also 
> see whether there are any additional improvements we should make.
> 
> This patch should apply cleanly to the PHP 5.2 CVS tree. 
> There's not much tuning that needs to be done. It uses 
> malloc() to allocate large memory blocks. You can control the 
> size of these blocks by setting the ZEND_MM_SEG_SIZE 
> environment variable before starting Apache/PHP. You may use 
> K or M to play around with the block size. The default we are 
> using is 256KB which seems to be a good balance.
> 
> Any feedback would be appreciated!
> 
> Andi
> 
> --
>  To 
> unsubscribe, visit: http://www.php.net/unsub.php
