Permalink
Switch branches/tags
Nothing to show
Commits on Sep 5, 2011
  1. [Perf/HPHPi] Speed up BinaryOpExpression and ArrayElementExpression

    Summary:
    I did some preprocessing on BinaryOpExpression and ArrayElementExpression
    to record at compile time so we can do faster fetch for common cases:
    VariableExpression and ScalarValueExpression. We can avoid a virtual call
    to eval, and also a Variant copy construction because the context is a
    CVarRef context and the copy is not needed.
    I also fixed a race condition that existed because of Variant stored in
    ConstantExpression. It is replaced by ScalarValueExpression by the optimizer
    and the Variant in ScalarValueExpression becomes static. Changed the rand()
    call to use the pointer as random number instead to avoid some perf cost.
    
    Test Plan:
    make fast_tests
    make slow_tests
    flib/unit test
    
    bench.php reduced from 39.x to 37.x.
    
    Reviewers: mwilliams, qigao
    
    Reviewed By: mwilliams
    
    CC: hphp-diffs@lists, ps, mwilliams
    
    Differential Revision: 317815
    myang committed with scottmac Aug 21, 2011
  2. [Perf] ObjectData::o_properties should be an Array

    Summary:
    For some reason it was an Array*, meaning that every use was indirected (and
    checked), in addition to the smart pointer indirect and check.
    
    This should be entirely good, since sizeof(Array) == sizeof(Array*) - so we're
    simply eliminating a level of indirection and checking, with no downside.
    
    Test Plan: fast_tests slow_tests
    
    Reviewers: myang, qigao
    
    Reviewed By: myang
    
    CC: ps, mwilliams, myang
    
    Differential Revision: 317713
    markw65 committed with scottmac Aug 31, 2011
  3. Fixes for __isset and __unset.

    Summary:
    hphpc and hphpi had two bugs with __isset and __unset. First, expressions
    such as "unset($obj->prop)" were not propertly invoking the __unset method
    because the UseUnset attribute was not being set properly. Second, the
    runtime was not doing the recursion checks that the other magic property
    methods do. This diff fixes these issues appropriately.
    
    Test Plan:
    make fast_tests
    make slow_tests
    Run www in prod
    
    Reviewers: mwilliams, myang, kma, je
    
    Reviewed By: mwilliams
    
    CC: ps, mwilliams
    
    Differential Revision: 313898
    andrewparoski committed with scottmac Aug 27, 2011
  4. Remove checks for the ENABLE_LATE_STATIC_BINDING macro

    Summary:
    We've supported late static binding for a while now and always build with
    ENABLE_LATE_STATIC_BINDING macro set. Let's get rid of all these macro
    checks.
    
    Test Plan:
    Build hphp
    make fast_tests
    make slow_tests
    Build www
    
    Reviewers: kma, mwilliams, je, myang, qigao
    
    Reviewed By: je
    
    CC: ps, mwilliams, je
    
    Differential Revision: 314003
    andrewparoski committed with scottmac Aug 29, 2011
  5. [HPHPi] Allow the HPHPi optimizer to handle statement

    Summary:
    The HPHPi optimizer did not allow a statement AST to be replaced by a better
    one. The idea is not to disturb the statement so debugger won't be affected.
    However, I did find some cases a cheaper statement can be generated without
    disturbing the debugger. So I changed the optimizer framework to allow
    a statement AST to be replaced (only in the statement list for now). The
    constraint still remains though. So we optimize debuggable code rather than
    debug optimized code. No real optimization is done in this change.
    
    Test Plan: make fast_tests
    
    Reviewers: mwilliams, qigao
    
    Reviewed By: mwilliams
    
    CC: hphp-diffs@lists, ps, mwilliams, myang
    
    Differential Revision: 316514
    myang committed with scottmac Sep 1, 2011
  6. [Fix] Better error reporting and interrupt handling on LightProcess

    Summary:
    Currently LightProcess's loop is not handling EINTR well, and error
    reporting may set the errno to 0 from libafdt. This diff makes it
    slightly better in reporting and ignores EINTR when doing the poll.
    
    Test Plan: make fast_tests
    
    Reviewers: myang, mwilliams
    
    Reviewed By: myang
    
    CC: tlerios, ps, mwilliams, myang, qigao
    
    Differential Revision: 317036
    
    Task ID: 696061
    qigao committed with scottmac Sep 2, 2011
Commits on Sep 4, 2011
  1. [Fix] Constants from redeclared classes could cause compilation errors

    Summary: If a class constant from a redeclared class is used as a static
    initializer at a point where the redeclared class can be resolved, we need to
    use the class-id, rather than the class name.
    
    Test Plan: build www-dev with the new PHPUnit added.
    
    Reviewers: qigao, myang
    
    Reviewed By: qigao
    
    CC: ps, mwilliams, qigao
    
    Differential Revision: 317054
    
    Task ID: 696468
    markw65 committed with scottmac Sep 2, 2011
  2. [Perf/HPHPi] Micro-optimize for statement

    Summary:
    For statement relies on evalVector to evaluate a vector of init/cond/next
    expressions. Most of the time, there is only one expression in each vector.
    I made a change to avoid calling evalVector for the common case.
    
    Test Plan:
    make fast_tests
    make slow_tests
    
    Reviewers: qigao, mwilliams
    
    Reviewed By: qigao
    
    CC: hphp-diffs@lists, ps, mwilliams, qigao
    
    Differential Revision: 316752
    myang committed with scottmac Sep 1, 2011
  3. [Perf/HPHPi] Create variables on demand

    Summary:
    This is based on a diff that Stephen has left over and I made some edits.
    Currently when calling a function, we prepare a FuncScopeVariableEnvironment.
    As part of that, we preallocate all the variables as if they were all needed.
    However, if a function has a large number of variables but for a given
    invocation only a few of the variables are used, then we would have wasted
    time to allocate/deallocate those unused. Secondly, get_defined_vars()
    currently shows the variables in their declaration order which is different
    from PHP. This change basically does a on-demand allocation of function scope
    variables. This is more consistent with PHP and has perf benefit in the case
    mentioned above.
    
    Test Plan:
    make fast_tests
    make slow_tests
    flib/unit test
    This change has little impact on bench.php but I found that are real cases
    this would be more benefitial.
    
    Reviewers: mwilliams, qigao
    
    Reviewed By: mwilliams
    
    CC: hphp-diffs@lists, ps, mwilliams, myang
    
    Differential Revision: 316536
    myang committed with scottmac Aug 29, 2011
  4. [Perf/Codesize] Eliminate per-class cloneImpl and cloneSet

    Summary: Every class defined cloneImpl, and cloneSet, which were used by
    ObjectData::clone to implement cloning. Rewrite clone to use the property tables
    instead. This can often be faster, since it involves far fewer calls, and is
    much smaller.
    
    Test Plan: fast_tests slow_tests
    
    Reviewers: myang, qigao
    
    Reviewed By: myang
    
    CC: cbueno, ps, mwilliams, myang
    
    Differential Revision: 316442
    markw65 committed with scottmac Aug 31, 2011
Commits on Sep 3, 2011
  1. Add support for traits in hphpc

    Summary:
    Implement traits (new to PHP 5.4) in hphpc.
    
    Traits RFC is available at:
    https://wiki.php.net/rfc/horizontalreuse
    
    However, this doc is not complete and many nuances I found by playing
    with Zend 5.4-alpha and the tests it includes.
    
    Test Plan:
    tested & compared with Zend 5.4 on 40+ Zend tests and 60+ tests I wrote
    make fast_tests
    make slow_tests
    built www
    
    Reviewers: mwilliams, qigao, myang, andrewparoski
    
    Reviewed By: mwilliams
    
    CC: ps, mwilliams, ottoni
    
    Differential Revision: 313841
    ottoni committed with scottmac Jul 26, 2011
  2. [Fix/Stable] Use delete[] to match with new[]

    Summary:
    My previous memory leak fix had a problem: m_stack = new Argument[] should be
    paired by delete[] m_stack, otherwise the semantics would be wrong (I guess
    make fast_tests was passing by chance and is not reliable).
    
    Test Plan:
    make fast_tests
    do a production run with ArgStack/TempStack temporarily enabled to confirm
    
    Reviewers: qigao, mwilliams
    
    Reviewed By: qigao
    
    CC: hphp-diffs@lists, ps, mwilliams, qigao
    
    Differential Revision: 316512
    myang committed with scottmac Sep 1, 2011
  3. [Fix/HPHPi] Fix memory leak in HPHPi

    Summary:
    This is the second part of fixing the memory leak in ArgArray and TempStack.
    I went over the semantics and concluded that adding destructors are good
    enough, with one additional change needed to ensure we have Variants always
    unset when stack pop occurs. Assertions were added.
    
    Test Plan:
    make fast_tests
    make slow_tests
    
    Reviewers: qigao, mwilliams
    
    Reviewed By: qigao
    
    CC: hphp-diffs@lists, ps, mwilliams, qigao
    
    Differential Revision: 316474
    
    Task ID: 692826
    myang committed with scottmac Sep 1, 2011
  4. [Server] add pagelet queue limit

    Summary:
    Currently if pagelet threads are used up, the pagelet request will get
    queued up. This diff is a simple safety feature that allows the queue
    limit controlled by config. This way, the client can fallback not using
    pagelet request instead of getting a PageletTask that never finishes or
    takes very long to finish.
    
    Test Plan: make fast_tests
    
    Reviewers: mwilliams, myang
    
    Reviewed By: myang
    
    CC: ps, mwilliams, danielw, robinz, qigao, myang
    
    Differential Revision: 316456
    
    Task ID: 695110
    qigao committed with scottmac Sep 1, 2011
Commits on Sep 2, 2011
  1. [Fix] Fix the posix_getrlimit

    Summary:
    ArrayData::set(litstr, ...) will not copy the string, the string there
    is allocated on stack so by the time it is used for printing, it
    contains garbage data. This diff added a wrapper for that to make sure
    the string is valid.
    
    Test Plan:
    make fast_tests
    try posix_getrlimit manually
    
    Reviewers: mwilliams, myang
    
    Reviewed By: mwilliams
    
    CC: ps, mwilliams
    
    Differential Revision: 316134
    
    Task ID: 694960
    qigao committed with scottmac Sep 1, 2011
  2. Add new json_encode() options to match PHP 5.3

    Summary: We now support all the extra parameters to json_encode()
    
    Test Plan:
    fast_tests
    slow_tests
    script from php manual
    <?php
    $a = array('<foo>',"'bar'",'"baz"','&blong&');
    
    echo "Normal: ", json_encode($a), "\n";
    echo "Tags: ",   json_encode($a, JSON_HEX_TAG), "\n";
    echo "Apos: ",   json_encode($a, JSON_HEX_APOS), "\n";
    echo "Quot: ",   json_encode($a, JSON_HEX_QUOT), "\n";
    echo "Amp: ",    json_encode($a, JSON_HEX_AMP), "\n";
    echo "All: ",    json_encode($a, JSON_HEX_TAG | JSON_HEX_APOS | JSON_HEX_QUOT |
    JSON_HEX_AMP), "\n\n";
    
    $b = array();
    
    echo "Empty array output as array: ", json_encode($b), "\n";
    echo "Empty array output as object: ", json_encode($b, JSON_FORCE_OBJECT),
    "\n\n";
    
    $c = array(array(1,2,3));
    
    echo "Non-associative array output as array: ", json_encode($c), "\n";
    echo "Non-associative array output as object: ", json_encode($c,
    JSON_FORCE_OBJECT), "\n\n";
    
    $d = array('foo' => 'bar', 'baz' => 'long');
    
    echo "Associative array always output as object: ", json_encode($d), "\n";
    echo "Associative array always output as object: ", json_encode($d,
    JSON_FORCE_OBJECT), "\n\n";
    
    Reviewers: mwilliams
    
    Reviewed By: mwilliams
    
    CC: ps, mwilliams
    
    Differential Revision: 296646
    
    Task ID: 614206
    scottmac committed Aug 4, 2011
Commits on Aug 31, 2011
  1. [Fix] Handle array_map with callback being null

    Summary:
    When array_map is called with callback being null, we did the right
    thing but gives an unnecessary warning. This diff fixes that.
    
    Test Plan:
    make fast_tests
    manually tried with function with array_map(null, $a, $b);
    
    Reviewers: mwilliams
    
    Reviewed By: mwilliams
    
    CC: ps, mwilliams
    
    Differential Revision: 315680
    
    Task ID: 693243
    qigao committed with scottmac Aug 31, 2011
  2. [Nemo] Dont assume anything about unknown functions

    Summary:
    The compiler assumes it sees the entire program. This can result in false
    assumptions - eg that unknown functions dont mutate their arguments. When
    running nemo in diff-at-a-time mode, we need to break that assumption due to
    cases like:
    
      function fiz(array $a) {}
      function bar() {
        $x = "hello";
        foo($x);
        fiz($x);
      }
    
    With the whole program assumption, we assume foo takes its argument by value,
    and that fiz is passed a string, rather than an array, and we spit out a warning
    about it. But foo may in reality assign an array to $x.
    
    I've added Option::WholeProgram (defaults to true) to fix this. We will
    probably want to make more use of this option going forwards.
    
    Test Plan: fast_tests slow_tests, no change to generated files for www-dev.
    
    Reviewers: qigao, myang
    
    Reviewed By: qigao
    
    CC: ps, mwilliams, qigao
    
    Differential Revision: 315584
    markw65 committed with scottmac Aug 31, 2011
  3. [Fix] Deal with parse errors more cleanly

    Summary:
    When parsing fails, we were left with half-finished classes and methods, which
    often failed to meet the expected invariants, resulting in crashes or
    assertions.
    
    Add a cleanup step to remove all the classes and functions from a FileScope
    when parsing fails. A later diff can create a pseudoMain with a suitable runtime
    error - for now we will just get file-not-found if you try to include a file
    with a syntax error (thats the same as current behavior, except that half the
    time we get compilation errors, or hphp crashes).
    
    Test Plan: fast_tests, slow_tests. Introduced lots of syntax errors into www,
    and built it. No crashes from hphp, no uncompilable files, and no linker errors.
    
    Reviewers: qigao, myang
    
    Reviewed By: qigao
    
    CC: ps, mwilliams, qigao
    
    Differential Revision: 314639
    
    Task ID: 686329
    markw65 committed with scottmac Aug 29, 2011
  4. [Fix/Stable] Fix memory leak

    Summary:
    In my recent change to improve HPHPi performance, I introduced ArgArray
    and TempStack. There was memory leak as destructors are missing. I turn
    them off for production as a quick fix and will work on a better fix later.
    
    Test Plan:
    make fast_tests
    make slow_tests
    make www, production test
    pq.php showed memory stabilized.
    
    Reviewers: ps, qigao
    
    Reviewed By: qigao
    
    CC: hphp-diffs@lists, ps, mwilliams, qigao, myang
    
    Differential Revision: 315450
    myang committed with scottmac Aug 31, 2011
  5. [Nemo] Generate CodeErrors for overridden final methods

    Summary:
    Rewrite ClassScope::collectMethods to identify overridden methods more
    accurately, and then add InvalidOverride errors if the overridden method is
    marked final.
    
    Updated code_error.php to include both file/line locations for errors which
    have two (such as InvalidOverride) in --list mode.
    
    Test Plan: fast_tests slow_tests. Build www-dev and inspect InvalidOverride
    errors to verify they are all real. Also inspect diffs in generated code to
    verify they are correct (and strictly better than before). There weren't many
    changes, but every case was due a two-phase method lookup getting translated to
    a direct call.
    
    Reviewers: myang, qigao, oyamauchi
    
    Reviewed By: qigao
    
    CC: ps, mwilliams, qigao
    
    Differential Revision: 314892
    markw65 committed with scottmac Aug 30, 2011
  6. [Fix/Stable] Restore a line accidentally deleted

    Summary:
    I accidentally removed a line in my previous check in, Restored.
    Task ID: #
    
    Blame Rev:
    
    Reviewers:
    qigao
    CC:
    
    Test Plan:
    make fast_tests
    make www and check no crash
    Revert Plan:
    
    Tags:
    
    - begin *PUBLIC* platform impact section -
    Bugzilla: #
    - end platform impact -
    myang committed with scottmac Aug 30, 2011
  7. [Fix/stable] Fix perflab build

    Summary: perflab uses RANDOMIZE_CXX_SOURCES, and one of my recent changes broke
    that.
    
    Test Plan: build www with and without RANDOMIZE_CXX_SOURCES=1
    
    Reviewers: qigao, myang
    
    Reviewed By: myang
    
    CC: boris, ps, mwilliams, myang
    
    Differential Revision: 314641
    
    Task ID: 692098
    markw65 committed with scottmac Aug 30, 2011
  8. [Perf/HPHPi] Make static strings unique in HPHPi

    Summary:
    HPHPi sometimes need to scan the m_alist to find the Variant of a given
    name. I tried to make m_alist an Array so the lookup can be faster. However,
    it actually hurts performance because of the Array overhead. This is probably
    because that most functions do not have a large number of local variables/
    parameters to warrant the use of an Array for faster lookup. So instead, I
    made a change to ensure that all the StaticStrings are unique. If we have
    this property, then we can avoid the cost of doing length check or memcpy
    when both names are static (which is highly likely). We may have other
    places where a unique StaticString may help to speedup lookups.
    
    Test Plan:
    make fast_tests
    make slow_tests
    flib/unit test
    bench.php gets a little under 40s (e.g, 39.791)
    
    Reviewers: mwilliams, qigao
    
    Reviewed By: qigao
    
    CC: hphp-diffs@lists, ps, mwilliams, qigao
    
    Differential Revision: 313940
    myang committed with scottmac Aug 26, 2011
  9. [hphpd] default the frame to the caller when encounter hphpd_break()

    Summary:
    hphpd_break() will be a dummy frame with no interesting stuff. This diff
    makes it default to the upper frame, which is what programmers expect to
    see. This diff also makes where command keep the frame.
    
    Test Plan:
    make fast_tests
    manually tried with hphpd_break()
    
    Reviewers: myang, mwilliams
    
    Reviewed By: mwilliams
    
    CC: ps, mwilliams
    
    Differential Revision: 314161
    
    Task ID: 684638
    qigao committed with scottmac Aug 29, 2011
  10. Remove use of dlopen in test runner

    Summary:
    Previously, to run tests, the 'run' binary would dlopen the
    libtest.so shared library for the current test and run its
    'main' function.  This caused problems with glibc, as it has
    an issue where using pthread_join in static initializers
    when run via dlopen causes a deadlock:
      - http://sourceware.org/bugzilla/show_bug.cgi?id=12307
      - https://bugzilla.redhat.com/show_bug.cgi?id=661676
    The problem occurs when initializing newer versions of the
    mysql library (newer versions than what is in the HPHP externals
    repo, which is why the problem hasn't been seen yet), which is
    used from the fbcode third-party repository.
    
    This diff replaces the use of dlopen in the test runner to
    use the dynamic linker instead.  This required building against
    a dummy libtest.so, then using LD_LIBRARY_PATH to point the
    test runner to the correct libtest.so when running the actual
    tests.
    
    Test Plan:
    Ran slow tests for builds of HPHP
    1) Against its own externals tree
    2) Against the fbcode gcc-4.4.5-glibc-2.11.2 externals tree
    3) With TAINTED=1
    
    Reviewers: mwilliams, ldbrandy, gpatangay
    
    Reviewed By: mwilliams
    
    CC: mwang, ps, mwilliams, ldbrandy
    
    Differential Revision: 311686
    andrewjcg committed with scottmac Aug 24, 2011
  11. [Fix/HPHPi] Fix bug in ArgArray

    Summary:
    Assertion was triggered on a number of functions that ArgArray did not
    implement. I did another pass and found the cases where we do read-only
    operations on ArgArray. New test added to catch where the assertions
    failed. There a still a number of assertions remain. They are either
    try to mutate the array (which does not make sense for ArgArray and
    the ArgArray should have been escalated if such a case), or represents
    a misuse of ArgArray (nonSmartCopy, onSetStatic, onSetEvalScalar, and
    ArgArray copy constructor).
    
    Test Plan:
    make fast_tests
    make slow_tests
    
    Reviewers: mwilliams, qigao
    
    Reviewed By: mwilliams
    
    CC: hphp-diffs@lists, ps, mwilliams
    
    Differential Revision: 312913
    myang committed with scottmac Aug 25, 2011
  12. [Fix] Search for constants in the correct order

    Summary:
    When looking for class constants, hphp would search each base class in turn.
    Because of the structure of the code, if the class implemented multiple
    interfaces, and neither the parent class, nor the first interface declared the
    constant, we would record the constant as missing, even though we went on to
    find the constant correctly.
    
    Rewrote to have a recursive step that finds the constant, without reporting
    errors, and a (more-or-less) non-recursive step to do the checking.
    
    Test Plan: fast_tests slow_tests, no more false positives for
    UseUndeclaredConstant in classes with complex interface hierarchies.
    
    Reviewers: qigao, myang
    
    Reviewed By: myang
    
    CC: ps, mwilliams, myang
    
    Differential Revision: 313830
    
    Task ID: 614967
    markw65 committed with scottmac Aug 29, 2011
  13. [Perf/Codesize] Remove cls::os_static_initializer

    Summary:
    The property tables already contain all the information needed to do this.
    
    For each class remove cls::os_static_initializer and csi_cls, and remove the
    call to csi_cls from GlobalVariables::initialize(). Do the initialization from
    Globals::initialize(), which is driven by the property tables, instead.
    
    Test Plan: fast_tests slow_tests, build www and browse the site. flib/unit
    tests.
    
    Reviewers: qigao, myang
    
    Reviewed By: myang
    
    CC: ps, mwilliams, myang
    
    Differential Revision: 313180
    markw65 committed with scottmac Aug 25, 2011
  14. [Fix] Fix potential crash when string too large

    Summary:
    When a string is too large, we free m_data and set m_data to NULL. However,
    we do not clear m_len to 0 and that creates an inconsistency between m_data
    and m_len. If the StringData is later used as LHS in concat_assign, we can
    end up trying to copy m_len bytes into NULL.
    
    Test Plan: make fast_tests
    
    Reviewers: qigao, mwilliams
    
    Reviewed By: qigao
    
    CC: hphp-diffs@lists, ps, mwilliams, qigao
    
    Differential Revision: 313339
    myang committed with scottmac Aug 27, 2011
  15. [Fix] parallel query doesn't retry connections

    Summary:
    Parallel query does a retry when the connection is successfully opened but
    the query fails. It does so by reopening the connection and retry the query.
    Reopening the connection involves closing the previous one if any and
    re-establish the connection from scratch. However, if the first connection
    fails, it makes no attempt to try reopening the connection and bails out
    immediately. I made a change so that if the first connection fails and the
    retryQueryOnFail is true, subsequent attempts are made to open the connection
    again until success or a maximum number is reached. This may help if the first
    connection failure is due to network glitch. I also made the number of
    query retries controled by a similar runtime option.
    
    Test Plan:
    make fast_tests
    make slow_tests
    
    Reviewers: qigao, mwilliams
    
    Reviewed By: qigao
    
    CC: rthiessen, hfisk, hphp-diffs@lists, ps, mwilliams, qigao
    
    Differential Revision: 313107
    
    Task ID: 637591
    myang committed with scottmac Aug 26, 2011
Commits on Aug 27, 2011
  1. [Fix] Line number reporting is broken for certain error conditions

    Summary:
    If a backtrace is taken between the time a new FrameInjection frame is pushed
    and its line number is set (e.g. calling an abstract method), the top frame has
    a line number of 0, which is useless in error reporting. Omit the frame if it
    hasn't had a line number set yet.
    
    Test Plan: fast_tests, slow_tests, test case from the task
    
    Reviewers: mwilliams, myang, qigao
    
    Reviewed By: mwilliams
    
    CC: hphp-diffs@lists, ps, mwilliams
    
    Differential Revision: 312983
    
    Task ID: 689283
    oyamauchi committed with scottmac Aug 26, 2011
  2. [HPHP Tainting] Enable pinging hphp and server binaries for taint

    Summary: title
    
    Test Plan:
    compiled hphp and www w/ and w/o tainting and ran with option
    --taint-status; got expected results
    
    Reviewers: gpatangay, mwilliams, srenfro
    
    Reviewed By: gpatangay
    
    CC: hphp-diffs@lists, ps, mwilliams, mwang, gpatangay
    
    Differential Revision: 312613
    mxw committed with scottmac Aug 26, 2011
  3. [HPHP Tainting] Cleanup

    Summary:
    This is just a bit of cleanup, but deserves maybe a bit of explanation:
    - I removed the set/clear mask NO_TRACE system. Even after a thorough
      IDL audit, these don't seem to have any real use. We may someday want
      the ability to delay tracing in PHPland (which is somewhat like the
      set_mask functionality), but implementing this at the TaintObserver
      level would require some kind of mask inheritance, which is
      undesireable. Similarly, the TaintTracerSwitchGuard has functionality
      like clear_mask.
    - I also removed the helper macro for TAINT_FLAG_HTML_CLEAN because it
      is rather taint-like and looks more consistent without the wrapper.
    - Removed comments that are at this point covered in the README.
    - Also fixed a trace message.
    
    Test Plan: ran some requests in hphpi
    
    Reviewers: srenfro, amenghra, mwilliams
    
    Reviewed By: amenghra
    
    CC: ps, mwilliams, amenghra
    
    Differential Revision: 312566
    mxw committed with scottmac Aug 26, 2011
  4. [HPHP Tainting] Generalizing trace guard system

    Summary:
    Title; this is done in anticipation of other traces, like
    TAINT_BIT_TRACE_SELF.
    
    Test Plan: ran a lot of requests in hphpi with trace activated
    
    Reviewers: mwilliams, srenfro, amenghra
    
    Reviewed By: srenfro
    
    CC: ps, mwilliams, srenfro, amenghra
    
    Differential Revision: 312552
    mxw committed with scottmac Aug 25, 2011