facebook hack 试用

fedora 20下安装hhvm

vim /etc/yum.repos.d/hhvm.repo

name=HHVM for Fedora $releasever - $basearch


wget http://dl.hhvm.com/conf/hhvm.gpg.key
sudo rpm --import hhvm.gpg.key
sudo yum install hhvm


PHP hello world

hhvm -m daemon -p 9910 t.php
ab -n10000 -c100 http://localhost:9910/t.php  # 15687/sec
ab -n10000 -c100 http://localhost/t.php # nginx+fpm: 11016/sec

Yii test

hhvm -m daemon -p 9910 yiitest/index.php 
ab -n10000 -c100 http://localhost:9910/yiitest/index.php # 4039/sec
ab -n10000 -c100 http://localhost/yiitest/index.php # nginx+fpm: 259/sec

vim hack.php

echo 'hello';

test hack.php

hhvm -m daemon -p 9910 hack.php 
ab -n10000 -c100 http://localhost:9910/hack.php # 15169/sec 基本无变化,可能因为程序太简单


您的电子邮箱地址不会被公开。 必填项已用*标注

To create code blocks or other preformatted text, indent by four spaces:

    This will be displayed in a monospaced font. The first four 
    spaces will be stripped off, but all other whitespace
    will be preserved.
    Markdown is turned off in code blocks:
     [This is not a link](http://example.com)

To create not a block, but an inline code span, use backticks:

Here is some inline `code`.

For more help see http://daringfireball.net/projects/markdown/syntax