Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Branch: master
Commits on Dec 18, 2012
  1. @sgolemon

    libxml2 2.9.0+ compat fix; xmlBuf changed to anonymous struct

    sgolemon authored
    Define wrappers for accessing size/contents on older versions
    of libxml2 which match the function protos in 2.9.0 and later.
    Thanks to github/nareshv for finding the issue and providing a fix.
  2. @sgolemon

    Add a timeout to pagelet_server_task_result + fix return code

    ide authored sgolemon committed
    The PHP master that calls into pagelet server currently needs to wait
    indefinitely on the worker. This adds an optional timeout parameter so that the
    PHP master can timeout after e.g. 10 seconds and log a descriptive message
    rather than dieing with the generic message of "the request timed out after 30
    There was also a bug with the return code for partial flushed responses.
    Sometimes the PHP master would receive a bogus return status like 65353. I
    traced this down to the fact that the return code was never set for partial
    responses, so it would be the initial value of `int rcode` on the stack.
  3. @jdelong @sgolemon

    Make hhvm not a hphpc-compiled script

    jdelong authored sgolemon committed
    Separates hhvm from hphpc.  (This will mean we don't have to
    compile hphpc when iterating on VM changes, and will help for eventual
    hphpc-deprecation.)  Details:
       - Stubs for hphpc-externals symbols that can't yet be removed.
       - src/system now includes g_system_class_map, which is essentially
         what the hhvm class map contained (only system stuff, plus things
         from constants.php).
       - VM::ProcessInit was the only part of the runtime that depended on
         libext_hhvm---breaks that dependency using a function pointer for
         now so you can link hphp_runtime without linking ext_hhvm.
       - Remove dlsym usage to access compiler symbols, using function
         pointers for now too.
  4. @sgolemon

    Refactor idl.php and remove some unused module features

    sgolemon authored
    Crutch is long dead.
    idl/base.php hasn't supported DeclaredDynamic in some time.
  5. @ottoni @sgolemon

    Make separate IR instructions for guard type checks

    ottoni authored sgolemon committed
    LdLoc and LdStack, when provided a label, also do the type check, and
    that's how guards were being implemented.  Although that has the nice
    effect of hoisting the loads early in the trace, it's bad because the
    loads effectively end up as part of the guards and they execute
    redundantly when guards fail.
    This diff splits the checks into their own instructions, but also
    loads all the dependencies right after the guards to preserve the
    hoisting effect.
Commits on Dec 17, 2012
  1. @sgolemon

    IR, stat counters for IR code

    mpal authored sgolemon committed
    Report dynamic counts for execution of IR translations
  2. @ottoni @sgolemon

    Add support for relaxed guards in HHIR

    ottoni authored sgolemon committed
  3. @ottoni @sgolemon

    Pass to the IR statically inferred types for tracelet-produced values

    ottoni authored sgolemon committed
    Values produced by the tracelet which had their values inferred by
    static analysis were not being passed to the IR.  This was not only
    bad for performance, but it was only causing correctness issues (see
    new test, which used to fail in repo-authoritative mode).
  4. @sgolemon

    class_implements should use autoload if specified

    aravind authored sgolemon committed
  5. @markw65 @sgolemon

    Add fb_autoload_map

    markw65 authored sgolemon committed
    fb_autoload_map($map, $root) specifies a mapping
    from classes, functions and constants to the files
    that define them. The map has the form:
      array('class'    => array('cls' => 'cls_file.php', ...),
            'function' => array('fun' => 'fun_file.php', ...),
            'constant' => array('con' => 'con_file.php', ...),
            'failure' => callable);
    If $root is non empty, it is prepended to every filename
    (so will typically need to end with '/').
    If the 'failure' element exists, it will be called if the
    lookup in the map fails, or the file cant be included. It
    takes a kind ('class', 'function' or 'constant') and the
    name of the entity we're trying to autoload.
    You can supply the autoload map to hphpc at compile time.
    Currently, this is just used to augment hphpc's parseOnDemand
    feature. It will use the map it to find more files to add to
    the build based on class/function and constant names used.
    This becomes necessary when all the requires are removed.
  6. @ottoni @sgolemon

    Trace through jumps that don't break tracelets

    ottoni authored sgolemon committed
    This ability was added to Tx64, but not to the IR.
    It was causing the IR to end a trace prematurely.
  7. @sgolemon

    Don't free VM stack for RCPRequestHandler

    aravind authored sgolemon committed
    For RPCRequestHandler threads, the ExecutionContext can stay alive
    across requests, and hold references to the VM stack. Make
    sure we don't free the stack from under the ExecutionContext.
  8. @markw65 @sgolemon

    Fix order of evaluation for locals in ArrayPairExpression

    markw65 authored sgolemon committed
    $a = 'foo';
    $a = array($a => $x[$a = 'bar']);
    should be equivalent to
    $a = array('bar' => $x['bar']);
    but hhvm was treating it as
    $a = array('foo' => $x['bar']);
    In production mode, some code transformations resulted in code similar to
    the above example, which hhvm then mis-interpreted.
  9. @paroski @sgolemon

    Add another test for optional types

    paroski authored sgolemon committed
  10. @swtaarrs @sgolemon

    Kill CGetM_GE

    swtaarrs authored sgolemon committed
  11. @swtaarrs @sgolemon

    Remove a couple big macros from translator-x64-vector.cpp

    swtaarrs authored sgolemon committed
    Equivalent functionality is achieved with tables of member
    function pointers. This should make debugging much nicer.
  12. @ottoni @sgolemon

    Call a helper for decref'ing popped stack values (PopR/V/C)

    ottoni authored sgolemon committed
    Call a generic decref helper for PopR/V/C. Added an additional
    helper entry point for the case where we are decref'ing TOS, which happens
    for PopR.
  13. @sgolemon

    Set parent when inserting instruction into a trace

    njormrod authored sgolemon committed
    ir.h contained an outdated and unused declaration for
    eleminateDeadCode. It has been removed.
    opt.cpp has a bug whereby an instruction is inserted into a trace, but
    the backedge (IRInstruction's m_parent) is not being correctly set to
    the trace. This has been fixed.
  14. @sgolemon
  15. @paroski @sgolemon

    Parser/lexer refactorage

    paroski authored sgolemon committed
    This diff cleans up some issues in the lexer and parser with XHP tags
    and other stuff.
  16. @jdelong @sgolemon
  17. @jdelong @sgolemon

    Add licenses to a few files in src/util/tests

    jdelong authored sgolemon committed
  18. @sgolemon

    Emit default values for FCallBuiltin

    aravind authored sgolemon committed
    Add support for default values in FCallBuiltin.
  19. @sgolemon

    FCallBuiltin for reference return types

    aravind authored sgolemon committed
    Add support for builtins with return by reference.
  20. @sgolemon

    Clean up uses of printf without arguments.

    sgolemon authored
    Gets rid of a lot of warnings in the cmake build,
    and allows us to set -Werror=format-security to catch
    potentially broken calls.  Mostly codemod changes.
  21. @sgolemon

    Inlined calls to native builtins in the IR.

    alia authored sgolemon committed
    Inlined calls to native builtins in the IR.
Commits on Dec 13, 2012
  1. @ottoni @sgolemon

    Move prologue redispatch code to 'a'

    ottoni authored sgolemon committed
    This code is hot, so put it in 'a' instead of 'astubs'.
  2. @swtaarrs @sgolemon

    Enable the AdminServer in config-server.hdf

    swtaarrs authored sgolemon committed
    Now that the admin server isn't enabled by default, we have
    to turn it on in the config for TestServer. Also fixed up
    test_server.cpp so individual tests can be run.
  3. @sgolemon

    Implemented call-ret support in IR.

    alia authored sgolemon committed
    Implemented suport for using the ret instruction in the IR.
  4. @sgolemon

    Changed CG_PUNT macro to print its argument.

    alia authored sgolemon committed
    Change the CG_PUNT macro in codegen.cpp so that it prints its argument
    instead of its function. This allows us to get much more precise reasons
    for why codegen punted.
  5. @ottoni @sgolemon

    Add support to FPushObjMethodD for fast method lookup using known class

    ottoni authored sgolemon committed
    FPushObjMethodD implementation in HHIR was lacking a fast-path
    implemented in TranslatorX64, namely when the base class is known.
  6. @sgolemon

    Supported BareThis, IncStat, and SetOpL in the IR.

    alia authored sgolemon committed
    Added HHIR support for 3 bytecodes, IncStat, SetOpL, and BareThis.
    These showed up among the top reasons the IR punts in a sandbox run.
  7. @edwinsmith @sgolemon

    NewTuple IR implementation

    edwinsmith authored sgolemon committed
    Add support for NewTuple.  The new_tuple helper function needs
    the count and values passed to it on the stack, which is like
    a call instruction but unlike most other IR instructions.
  8. @kmafb @sgolemon

    Turn on CGetM type prediction.

    kmafb authored sgolemon committed
    This diff enables the dormant CGetM type prediction code.
    This affects tracelet geometry, sometimes making the trace guards explode.
    To compensate, I appear to need two new heuristics:
    1. give up on type prediction if we're in a polymorphic trace
    2. don't inline returns in polymorphic traces.
    These two heuristics use different tracelet depths to kick in;
    an exhaustive search of an 8x8 matrix of parameters suggests (2,6)
    is the right setting for now.
  9. @kmafb @sgolemon

    Some refactoring to get rid of bogus KindOf*.

    kmafb authored sgolemon committed
    Let's try to keep internal bits out of DataType. This
    was an easy first step; I'll go after the other TypeCheck ones in
    a follow-on diff.
Something went wrong with that request. Please try again.