Live++ - C/C++ live coding

compiler_logos

Live++ enables live coding (hot-reload) for C/C++ applications, combining the power of rapid iteration with the speed of a compiled language.

Live++ compiles your changes in the background, directly patching the machine code of the running executable(s).
It links against existing code and data symbols, automatically persisting the state of global symbols, function static variables, and the like.
It works with any kind of C/C++ code and requires neither plug-ins nor a debugger or IDE.

Start your application from anywhere, edit its source code using your favourite editor, and let Live++ do the rest.

No matter if you are working on new features, trying out gameplay mechanics, optimizing code, or writing tests -
Live++ can massively cut down your iteration times.

Release notes

Features

  • Project setup agnostic

    Live++ doesn't care about your project setup. It works with .EXE, .DLL, and .LIB based projects, makefiles, and custom setups and build systems.

  • IDE agnostic

    Live++ does not require any IDE plug-ins or similar. Use any text editor or external tool for changing your application's source code.

  • Native toolchain

    Live++ uses the native toolchain which the executable was built with for compilation, and does not parse any source code.

  • Binary

    Live++ works at the binary level using .PDB, .EXE, .DLL, .LIB, and .OBJ directly. It extracts and reverses most of the needed information from executable and object files.

  • High compatibility

    Live++ is compatible with almost all compiler options, except whole program optimization. It supports linking with the static and dynamic run-time libraries.

  • Extensive C++ Support

    Live coding supports all C++ features such as RTTI, polymorphism, exceptions, etc. Live++ inherently supports all compiler-dependent features your code might use.

  • Lightweight

    The Live++ .DLL is very lightweight, adding only ~150 KiB to your application's memory footprint. Almost all information is kept in a separate process.

  • Single-machine multi-process editing

    Live++ lets you simultaneously apply changes to multiple running processes.

  • 32-bit and 64-bit

    Live++ fully supports x86/32-bit and x64/64-bit applications.

  • Special support for amalgamated/unity builds

    Live++ automatically detects and splits amalgamated/unity files. By leveraging a built-in object file cache along with dependency databases, split unity files persist even across Live++ sessions. This fully harnesses the shorter compile times provided by unity builds and at the same time delivers excellent single-file iteration times when using Live++ .

Stand-alone

Live++ does not care about what your C++ code looks like, as long as you meet the technical requirements. You don't have to rewrite parts of your code to make Live++ work.

Live++ does not care about the build system you use to compile your C++ code. FASTBuild, SN-DBS, IncrediBuild, and various in-house (distributed) build systems have been tested to work without requiring any additional setup.

Live++ does not care about which IDE you use and therefore supports executables and DLLs built using the following out of the box:

(*) when using the Visual Studio compiler/MSVC toolchain

Live++ does not care about how an EXE is started or by which application a DLL is loaded. It doesn't matter whether you have a main executable linked against several static libraries, a DLL-based plug-in loaded by a 3rd-party application such as Autodesk Maya®, or a game DLL loaded by an external application such as a C# editor - Live++ naturally supports all of these scenarios and any mix of modules and libraries.

As long as Live++ is enabled for your module (.EXE or .DLL), live coding will just work!

Simple integration

Integrating Live++ is very simple and usually requires less than 10 minutes:

  1. Adapt compiler and linker options to meet the technical requirements.
  2. Load the Live++ DLL and register a process group with a single line of code using the provided single-header C++ API.
  3. Enable Live++ for your module (and optionally its import DLLs) using another single line of code.

Read the online documentation for a quickstart guide

Unreal Engine 4 integration

kite_and_lightning Kite & Lightning developer ikrima has kindly provided a plug-in wrapper for Unreal Engine 4 available for free on GitHub.

See it in action

Additional C/C++ API

Live++ comes with an additional API that allows you to do even more advanced live coding, which would otherwise be impossible.


  • Structural changes

    Live++ offers pre- and post-patch hooks that allow you to even make changes to the memory layout of classes. Code like the example below allows you to add and remove members to and from classes.

    • livepp
      Pre- and post-patch hook API
  • Synchronization points

    Even though patching running executables using Live++ is always safe, the API enables you to emit synchronization points into your executable, ensuring that code patches are always applied at e.g. the start of a single frame.

    • livepp
      Synchronization point API

The Live++ API offers additional features such as temporarily disabling optimizations for functions or files - check the online documentation for more information!

  • Program debug database

    Live++ needs a full PDB file in order to extract some of the needed information about the executable.

  • Single .DLL

    Live coding requires the Live++ DLL to be loaded by your module.

  • Visual Studio compiler

    Code needs to be compiled and linked using a Visual Studio compiler (**).

(*) Subject to change, requirement might be removed in future versions
(**) Support for LLVM Clang and LLD in progress

Buy

Trial

Free
  • For non-commercial purposes
  • Limited to 30 days
  • Limited to 15 minutes per session
    (Live++ must be restarted)
  • 300 ms delay on recompiles
  • Does not include command-line tools
  • Includes sample application
Download now

Individual

€11.90 / month (excl. VAT)

€119.00 / year (excl. VAT)
(save 2 months vs. monthly purchases)

  • For commercial purposes
  • Fully-featured
  • License for professionals
    (e.g. freelance programmers)
  • Includes command-line tools for automated license management
  • Per-seat licenses
  • 50% discount for students and teaching staff available

Business

€19.90 / month (excl. VAT)

€199.00 / year (excl. VAT)
(save 2 months vs. monthly purchases)

By downloading any software of Molecular Matters e.U. from this site, you acknowledge that you have read the End User License Agreement (EULA), and that you understand and agree that you are bound by its terms and conditions.

Minimum system requirements: Microsoft® Windows® 7 32-bit or 64-bit.

Frequently asked questions

Supported IDEs & debuggers

No, you can start the executable from anywhere you want. As long as the technical requirements are met and the application has been compiled & linked with the correct settings, you are good to go.
Yes, Live++ yields PDB files for code patches and as such supports popular debuggers like Visual Studio and WinDbg out of the box.

Supported compilers & settings

No, not at the moment.
However, Live++ works in a very generic way, with only a handful of cases that need compiler-specific treatment. Support for LLVM Clang and LLD is already in progress and almost finished.
Get in touch with us if you want to help fix the last remaining issues (1, 2, 3).
Yes, Live++ is able to reconstruct the information needed for live coding directly from the binary files involved.
Yes!
Live++ has been tested with FASTBuild, SN-DBS, IncrediBuild, various proprietary in-house (distributed) build systems, and build systems used by IDEs other than Visual Studio.

Required code changes

No!
Apart from loading the Live++ .DLL and setting up the build options there is nothing else you have to do.
The API comes as a single header, with macros and functions for installing hooks and synchronization points. Each hook or synchronization point requires exactly one line of code.

Live++ has been tested extensively on several codebases and game engines of varying sizes. If you have followed all the required steps outlined in the online documentation and checked the FAQ for common mistakes and problems, but still cannot get Live++ to work with your setup, please do not hesitate to contact us directly.

We want to make Live++ work for everyone.

Roadmap

Short-term (Q2 and Q3 2018)

Make Live++ work directly with individual translation units that are part of an amalgamation. This should greatly improve recompile times when working with amalgamated builds.

Available in version 1.2.1.

Allow recompiling and patching code while the process is halted in the debugger.

Allow recompiling and patching code when a process crashes (e.g. caused by an access violation). This allows applications to recover from certain errors without having to perform a restart.

Pass context containing names of all types which had their data layout changed.

Make Live++ work with Clang and LLD on Windows.

Long-term (Q4 2018 and later)

Make Live++ support Xbox One.

Make Live++ support Linux.

Allow recompiling and patching code over the network on multiple machines running multiple processes.