The next HHVM release, 3.6, is on the horizon. We expect it to be released at the very end of February or in early March. It’s going to be a big release. Not only will it be our second release with long-term support, but it will contain several exciting new features – and lay the groundwork for continued development later this year.

New features in 3.6:

  • Long-awaited MySQL support for async functions in Hack! Hack’s async functions allow an application to continue executing code while fetching data, which can dramatically reduce the time it spends waiting for IO. We blogged a few weeks ago about async curl support, and with 3.6, MySQL will be usable with Hack’s async functions as well. This support comes from a new MySQL client library from the WebScaleSQL project; this is built-in to HHVM and will work with any recent MySQL server. Full documentation will be ready by the actual 3.6 release, but for early adopters, here is the internal API header.

  • While we’re at it, we added async support for memcache as well. Much of the code for this comes from the mcrouter open-source project, though again it does not require mcrouter and will work with any recent memcache server. Here’s the internal API header while we prepare documentation for this feature too for the 3.6 release.

  • A restructuring of the FastCGI server, which fixed several memory leaks and reliability issues, especially under very high load.

  • A multitude of other crash and memory leak fixes.

  • Native property handlers, an HHVM-internal feature for compatibility with existing PHP code. Previously, some PHP which used edge cases around __set/__get and sub-classing certain internal classes wouldn’t work on HHVM. With the addition of native property handlers in 3.6, it will work without modification.

  • Speaking of compatibility, 3.6 contains many fixes to make HHVM even more compatible with existing PHP code. As always, HHVM strives to maintain full compatibility with PHP. If your existing code doesn’t work on HHVM, please file an issue on GitHub!

  • Improved typechecking support for XHP in Hack.

Update 2015-02-18: if you can’t wait for the 3.6 official release, the above features are now available in any prebuilt nightly package dated 2015-02-18 or later.

But what’s coming out soon is only part of the story. The 3.6 release lays the groundwork for even more impressive components, which will let us continue making HHVM a highly performant, feature-rich PHP runtime.

HHVM roadmap for 2015:

  • Integration of LLVM as a further optimization step to make the hottest code run even faster on HHVM.

  • Continued experiments with support for 64-bit ARM platforms to increase deployment options for HHVM.

  • Improvements to the garbage-collection scheme for HHVM. This will start with collecting cyclic references and move into experiments with a full mark-and-sweep garbage collector, built on top of a pluggable GC interface.

  • Other general memory usage improvements, including investigation into several longstanding memory and stability issues.

  • First-class OS X support.

  • Even tighter integration of the Hack typechecker with HHVM, leading to an even easier experience getting started with and using Hack.

  • Full support for all configuration options in INI files (most are already supported), killing the HHVM-specific HDF files.

  • Releasing the 100% Hack XHP 2.0 library.

  • Continued compatibility fixes to make even more existing PHP code work without modification on HHVM.

So 3.6 will be an exciting release, and 2015 is shaping up to be an exciting year! As always, contributions of any kind are extremely welcome – whether they be questions, suggestions, bug reports, or code – and will always be viewed constructively. Check out the links in the sidebar to the right to get involved!

Comments


  • Casey: You guys are killing it. Thanks for all your work!
  • Elliot: These is a really exciting change-set. I'm desperate to get my hands on all of these things already!
  • Anatoly: Oh, GC of cyclic references! Really looking forward for this!
  • John: What about other rdbms, like PostgreSQL and/or SQLite? Is support for them considered or the demand is too low?
  • Josh Watzman: We haven't had significant demand for them, at least not to the level of MySQL. If you'd like to see it, feel free to file an issue on GitHub. I can't promise we'll be able to get to it soon, but it will definitely be good to have a place to track demand. (And if you, or someone else, wants to build support for us, we'd be happy to discuss there about what a good PR would look like! Definitely the way to ensure support gets added soonest.)
  • Dominic Watson: Woo! As soon as OSX support hits, I'm jumping on board with this.
  • Paul M: Awesome news about async for mysql and memcached. What about using APC as a key/value store? I'm doing that right now. Can async functionality be extended to that as well? Thanks
  • Josh Watzman: My understanding is that APC is local to the PHP/HHVM process, and never goes off-box, and so should always be very fast to access. If this isn't always the case, or you have some other use case for async APC, please file an issue on GitHub so we can track demand!
  • Kurre: I've tried HHVM on my upcoming site and I must say that it is super fast! But I need support for MSSQL connection before I can launch my site, any chance that you are working on this? :)
  • Josh Watzman: There's an issue open with some interest (https://github.com/facebook/hhvm/issues/1579) but I'm not aware of anyone actively working on it, unfortunately.
  • Lukas: both are important but SQLite is imho critical since its so huge to have a powerful DB right out of the box. Many applications use this to enable quick setup of their example apps.
  • Scott Arciszewski: Are you going to implement some of the PHP7 changes in HHVM? In particular, the migration of mcrypt from libmcrypt (which is abandonware) into a openssl shim, cache-timing-safe character encoding functions, an updated hash extension (adding: SHA-512/256, SHA-3, BLAKE2b, etc.) are features I plan on committing to PHP 7 that HHVM users may benefit from too. If you need me to manually submit these separately, just let me know.
  • Scott Arciszewski: I'm very surprised there isn't already a lot of demand for PostgreSQL. :)
  • Josh Watzman: There's been some demand for a general postgres plugin. One is provided by a third-party (who we've worked closely with a few times), it's at https://github.com/PocketRent/hhvm-pgsql, and that has been more than good enough for most people. If you haven't seen it before, you should give it a try! There hasn't been any demand yet for *async* versions of those functions, at least that I've seen.
  • Josh Watzman: Yep, we want to continue being compatible with PHP, and that includes the upcoming PHP7. I don't think we've started work on implementing any of the features yet, but we've definitely discussed how to go about several of them -- and PHP7 is still far enough away that we have plenty of time. If you want to contribute fixes for us, we'd love to take the PRs as well!
  • Andris: Async query support would come handy with PDO too.
  • castarco: Automatically updated (via APT) a server with a wordpress blog and owncloud installed (from HHVM 3.5 to HHVM 3.6) and now the server only responds with HTTP 404 error codes: "404 File Not Found" :( . Any idea to solve it? Thanks for yout time!
  • Josh Watzman: Can you please file a bug report at https://github.com/facebook/hhvm/issues, with as many details about your application, how it's configured, what else (if anything) you changed as part of the 3.6 upgrade, etc, as you know? Much easier to track bugs there than on our blog post :)