diff --git a/core/lib/Drupal/Core/CoreBundle.php b/core/lib/Drupal/Core/CoreBundle.php
index b0830a0..994ff18 100644
--- a/core/lib/Drupal/Core/CoreBundle.php
+++ b/core/lib/Drupal/Core/CoreBundle.php
@@ -43,24 +43,6 @@ class CoreBundle extends Bundle
     $container->register('language_manager', 'Drupal\Core\Language\LanguageManager')
       ->addArgument(new Reference('request'))
       ->setScope('request');
-
-    // @todo Replace below lines with the commented out block below it when it's
-    //   performant to do so: http://drupal.org/node/1706064.
-    $dispatcher = $container->get('dispatcher');
-    $matcher = new \Drupal\Core\LegacyUrlMatcher();
-    $content_negotation = new \Drupal\Core\ContentNegotiation();
-    $dispatcher->addSubscriber(new \Drupal\Core\EventSubscriber\RouterListener($matcher));
-    $dispatcher->addSubscriber(new \Drupal\Core\EventSubscriber\ViewSubscriber($content_negotation));
-    $dispatcher->addSubscriber(new \Drupal\Core\EventSubscriber\AccessSubscriber());
-    $dispatcher->addSubscriber(new \Drupal\Core\EventSubscriber\MaintenanceModeSubscriber());
-    $dispatcher->addSubscriber(new \Drupal\Core\EventSubscriber\PathSubscriber());
-    $dispatcher->addSubscriber(new \Drupal\Core\EventSubscriber\LegacyRequestSubscriber());
-    $dispatcher->addSubscriber(new \Drupal\Core\EventSubscriber\LegacyControllerSubscriber());
-    $dispatcher->addSubscriber(new \Drupal\Core\EventSubscriber\FinishResponseSubscriber());
-    $dispatcher->addSubscriber(new \Drupal\Core\EventSubscriber\RequestCloseSubscriber());
-    $container->set('content_negotiation', $content_negotation);
-    $dispatcher->addSubscriber(\Drupal\Core\ExceptionController::getExceptionListener($container));
-    /*
     $container->register('matcher', 'Drupal\Core\LegacyUrlMatcher');
     $container->register('router_listener', 'Drupal\Core\EventSubscriber\RouterListener')
       ->addArgument(new Reference('matcher'))
@@ -101,6 +83,5 @@ class CoreBundle extends Bundle
 
     // Add a compiler pass for registering event subscribers.
     $container->addCompilerPass(new RegisterKernelListenersPass(), PassConfig::TYPE_AFTER_REMOVING);
-    */
   }
 }
diff --git a/core/lib/Drupal/Core/DependencyInjection/ContainerBuilder.php b/core/lib/Drupal/Core/DependencyInjection/ContainerBuilder.php
index 0bc4d67..a5f0f17 100644
--- a/core/lib/Drupal/Core/DependencyInjection/ContainerBuilder.php
+++ b/core/lib/Drupal/Core/DependencyInjection/ContainerBuilder.php
@@ -7,6 +7,7 @@
 
 namespace Drupal\Core\DependencyInjection;
 
+use \ReflectionObject;
 use Symfony\Component\DependencyInjection\ContainerBuilder as BaseContainerBuilder;
 use Symfony\Component\DependencyInjection\Container;
 
@@ -18,6 +19,36 @@ use Symfony\Component\DependencyInjection\Container;
 class ContainerBuilder extends BaseContainerBuilder {
 
   /**
+   * Adds a resource for this configuration.
+   *
+   * This method is based on the addResource method in the parent class, but
+   * that method is reliant on the Config component which we do not use here.
+   *
+   * @param string $resource_filename A resource instance
+   *
+   * @return ContainerBuilder The current instance
+   *
+   * @api
+   */
+  public function addDrupalFileResource($resource_filename)
+  {
+    $this->resources[] = $resource_filename;
+    return $this;
+  }
+
+  /**
+   * Returns an array of resources loaded to build this configuration.
+   *
+   * @return string[] An array of resources
+   *
+   * @api
+   */
+  public function getResources()
+  {
+    return array_unique($this->resources);
+  }
+
+  /**
    * Overrides Symfony\Component\DependencyInjection\ContainerBuilder::addObjectResource().
    *
    * Drupal does not use Symfony's Config component, so we override
@@ -25,6 +56,11 @@ class ContainerBuilder extends BaseContainerBuilder {
    * container compilation.
    */
   public function addObjectResource($object) {
+    $parent = new ReflectionObject($object);
+    do {
+      $this->addDrupalFileResource($parent->getFileName());
+    }
+    while ($parent = $parent->getParentClass());
   }
 
   /**
diff --git a/core/lib/Drupal/Core/DrupalKernel.php b/core/lib/Drupal/Core/DrupalKernel.php
index 869b504..c5f59fc 100644
--- a/core/lib/Drupal/Core/DrupalKernel.php
+++ b/core/lib/Drupal/Core/DrupalKernel.php
@@ -12,6 +12,7 @@ use Symfony\Component\HttpKernel\Kernel;
 use Drupal\Core\DependencyInjection\ContainerBuilder;
 use Symfony\Component\Config\Loader\LoaderInterface;
 use Symfony\Component\DependencyInjection\ParameterBag\ParameterBag;
+use Symfony\Component\DependencyInjection\Dumper\PhpDumper;
 
 /**
  * The DrupalKernel class is the core of Drupal itself.
@@ -51,11 +52,47 @@ class DrupalKernel extends Kernel {
    * Initializes the service container.
    */
   protected function initializeContainer() {
-    // @todo We should be compiling the container and dumping to php so we don't
-    //   have to recompile every time. There is a separate issue for this, see
-    //   http://drupal.org/node/1668892.
-    $this->container = $this->buildContainer();
+    $class = $this->getContainerClass();
+
+    $cache_file = $class . '.php';
+    $metadata = $cache_file . '.meta';
+
+    $fresh = TRUE;
+
+    if (!is_file($cache_file) || !is_file($metadata)) {
+      $fresh = FALSE;
+    }
+    else {
+      $timestamp = filemtime($cache_file);
+      $meta = unserialize(file_get_contents($metadata));
+      foreach ($meta as $resource) {
+        if (!file_exists($resource)) {
+          $fresh = FALSE;
+          break;
+        }
+        else {
+          if (filemtime($resource) >= $timestamp) {
+            $fresh = FALSE;
+            break;
+          }
+        }
+      }
+    }
+
+    if (!$fresh) {
+      $container = $this->buildContainer();
+      $this->dumpDrupalContainer($cache_file, $container, $class, $this->getContainerBaseClass());
+    }
+
+    drupal_php_loader()->includePhp($cache_file);
+
+    $this->container = new $class();
     $this->container->set('kernel', $this);
+
+    if (!$fresh && $this->container->has('cache_warmer')) {
+      $this->container->get('cache_warmer')->warmUp($this->container->getParameter('kernel.cache_dir'));
+    }
+
     drupal_container($this->container);
   }
 
@@ -74,10 +111,8 @@ class DrupalKernel extends Kernel {
     foreach ($this->bundles as $bundle) {
       $bundle->build($container);
     }
-
-    // @todo Compile the container: http://drupal.org/node/1706064.
-    //$container->compile();
-
+    $container->addObjectResource($this);
+    $container->compile();
     return $container;
   }
 
@@ -91,6 +126,35 @@ class DrupalKernel extends Kernel {
   }
 
   /**
+   * Dumps the service container to PHP code in the config directory.
+   *
+   * This method is based on the dumpContinaer method in the parent class, but
+   * that method is reliant on the Config component which we do not use here.
+   *
+   * @param string           $cache_file     The full filename to write to.
+   * @param ContainerBuilder $container The service container
+   * @param string           $class     The name of the class to generate
+   * @param string           $baseClass The name of the container's base class
+   */
+  protected function dumpDrupalContainer($cache_file, ContainerBuilder $container, $class, $baseClass)
+  {
+    // cache the container
+    $dumper = new PhpDumper($container);
+    $content = $dumper->dump(array('class' => $class, 'base_class' => $baseClass));
+
+    if (!$this->debug) {
+      $content = self::stripComments($content);
+    }
+    $metadata = $container->getResources();
+    drupal_php_loader()->write($cache_file, $content);
+
+    if (null !== $metadata && true === $this->debug) {
+      $file = $cache_file.'.meta';
+      drupal_php_loader()->write($file, $serialize($metadata));
+    }
+  }
+
+  /**
    * Overrides and eliminates this method from the parent class. Do not use.
    *
    * This method is part of the KernelInterface interface, but takes an object
diff --git a/core/lib/Drupal/Core/EventSubscriber/FinishResponseSubscriber.php b/core/lib/Drupal/Core/EventSubscriber/FinishResponseSubscriber.php
index 56d5675..8fa548e 100644
--- a/core/lib/Drupal/Core/EventSubscriber/FinishResponseSubscriber.php
+++ b/core/lib/Drupal/Core/EventSubscriber/FinishResponseSubscriber.php
@@ -7,6 +7,7 @@
 
 namespace Drupal\Core\EventSubscriber;
 
+use Drupal\Core\Language\LanguageManager;
 use Symfony\Component\HttpKernel\Event\FilterResponseEvent;
 use Symfony\Component\HttpKernel\KernelEvents;
 use Symfony\Component\EventDispatcher\EventSubscriberInterface;
@@ -16,6 +17,12 @@ use Symfony\Component\EventDispatcher\EventSubscriberInterface;
  */
 class FinishResponseSubscriber implements EventSubscriberInterface {
 
+  protected $language_manager;
+
+  public function __construct(LanguageManager $language_manager) {
+    $this->language_manager = $language_manager;
+  }
+
   /**
    * Sets extra headers on successful responses.
    *
@@ -30,10 +37,7 @@ class FinishResponseSubscriber implements EventSubscriberInterface {
     $response->headers->set('X-UA-Compatible', 'IE=edge,chrome=1', false);
 
     // Set the Content-language header.
-    // @todo Receive the LanguageManager object as a constructor argument when
-    //   the dependency injection container allows for it performantly:
-    //   http://drupal.org/node/1706064.
-    $response->headers->set('Content-language', language_manager(LANGUAGE_TYPE_INTERFACE)->langcode);
+    $response->headers->set('Content-language', $this->language_manager->getLanguage(LANGUAGE_TYPE_INTERFACE)->langcode);
 
     // Because pages are highly dynamic, set the last-modified time to now
     // since the page is in fact being regenerated right now.
diff --git a/core/modules/system/tests/modules/bundle_test/lib/Drupal/bundle_test/BundleTestBundle.php b/core/modules/system/tests/modules/bundle_test/lib/Drupal/bundle_test/BundleTestBundle.php
index 768a1b0..c124007 100644
--- a/core/modules/system/tests/modules/bundle_test/lib/Drupal/bundle_test/BundleTestBundle.php
+++ b/core/modules/system/tests/modules/bundle_test/lib/Drupal/bundle_test/BundleTestBundle.php
@@ -20,9 +20,5 @@ class BundleTestBundle extends Bundle
   public function build(ContainerBuilder $container) {
     $container->register('bundle_test_class', 'Drupal\bundle_test\TestClass')
       ->addTag('kernel.event_subscriber');
-
-    // @todo Remove when the 'kernel.event_subscriber' tag above is made to
-    //   work: http://drupal.org/node/1706064.
-    $container->get('dispatcher')->addSubscriber($container->get('bundle_test_class'));
   }
 }
