diff --git a/core/lib/Drupal/Core/Entity/Entity.php b/core/lib/Drupal/Core/Entity/Entity.php
index 34aa09d..7504443 100644
--- a/core/lib/Drupal/Core/Entity/Entity.php
+++ b/core/lib/Drupal/Core/Entity/Entity.php
@@ -361,12 +361,12 @@ public function changed() {
     );
 
     foreach ($this->referencedEntities() as $referenced_entity) {
-      $referenced_entity_ids[$referenced_entity->entityType()][$referenced_entity->id()] = TRUE;
+      $referenced_entity_ids[$referenced_entity->entityType()][$referenced_entity->id()] = $referenced_entity;
     }
 
-    foreach ($referenced_entity_ids as $entity_type => $entity_ids) {
+    foreach ($referenced_entity_ids as $entity_type => $entities) {
       if (\Drupal::entityManager()->hasController($entity_type, 'render')) {
-        \Drupal::entityManager()->getRenderController($entity_type)->resetCache(array_keys($entity_ids));
+        \Drupal::entityManager()->getRenderController($entity_type)->resetCache($entities);
       }
     }
   }
diff --git a/core/lib/Drupal/Core/Entity/EntityRenderController.php b/core/lib/Drupal/Core/Entity/EntityRenderController.php
index fe6bd10..7fc1fa7 100644
--- a/core/lib/Drupal/Core/Entity/EntityRenderController.php
+++ b/core/lib/Drupal/Core/Entity/EntityRenderController.php
@@ -232,11 +232,13 @@ public function viewMultiple(array $entities = array(), $view_mode = 'full', $la
   /**
    * {@inheritdoc}
    */
-  public function resetCache(array $ids = NULL) {
+  public function resetCache(array $entities = NULL) {
     if (isset($ids)) {
       $tags = array();
-      foreach ($ids as $entity_id) {
-        $tags[$this->entityType][$entity_id] = $entity_id;
+      foreach ($entities as $entity) {
+        $tags[$this->entityType][$entity->id()] = $entity->id();
+        $tags[$this->entityType . '_view_' . $entity->bundle()] = TRUE;
+        $tags[$this->entityType . '_list_' . $entity->bundle()] = TRUE;
       }
       \Drupal::cache($this->cacheBin)->deleteTags($tags);
     }
diff --git a/core/lib/Drupal/Core/Entity/EntityRenderControllerInterface.php b/core/lib/Drupal/Core/Entity/EntityRenderControllerInterface.php
index a112fc2..2999944 100644
--- a/core/lib/Drupal/Core/Entity/EntityRenderControllerInterface.php
+++ b/core/lib/Drupal/Core/Entity/EntityRenderControllerInterface.php
@@ -79,10 +79,9 @@ public function viewMultiple(array $entities = array(), $view_mode = 'full', $la
   /**
    * Resets the entity render cache.
    *
-   * @param array|null $ids
-   *   (optional) If specified, the cache is reset for the given entity IDs
-   *   only.
+   * @param array|null $entities
+   *   (optional) If specified, the cache is reset for the given entities  only.
    */
-  public function resetCache(array $ids = NULL);
+  public function resetCache(array $entities = NULL);
 
 }
diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/cache/CachePluginBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/cache/CachePluginBase.php
index 1b948f1..486543f 100644
--- a/core/modules/views/lib/Drupal/views/Plugin/views/cache/CachePluginBase.php
+++ b/core/modules/views/lib/Drupal/views/Plugin/views/cache/CachePluginBase.php
@@ -7,8 +7,8 @@
 
 namespace Drupal\views\Plugin\views\cache;
 
+use Drupal\Core\Cache\Cache;
 use Drupal\Core\Language\Language;
-use Drupal\views\ViewExecutable;
 use Drupal\Core\Cache\CacheBackendInterface;
 use Drupal\views\Plugin\views\PluginBase;
 use Drupal\Core\Database\Query\Select;
@@ -94,7 +94,8 @@ public function summaryTitle() {
    * @param $type
    *   The cache type, either 'query', 'result' or 'output'.
    */
-  protected function cacheExpire($type) { }
+  protected function cacheExpire($type) {
+  }
 
    /**
     * Determine expiration time in the cache table of the cache type
@@ -109,7 +110,6 @@ protected function cacheSetExpire($type) {
     return CacheBackendInterface::CACHE_PERMANENT;
   }
 
-
   /**
    * Save data to the cache.
    *
@@ -126,17 +126,16 @@ public function cacheSet($type) {
           'total_rows' => isset($this->view->total_rows) ? $this->view->total_rows : 0,
           'current_page' => $this->view->getCurrentPage(),
         );
-        cache($this->table)->set($this->generateResultsKey(), $data, $this->cacheSetExpire($type));
+        \Drupal::cache($this->table)->set($this->generateResultsKey(), $data, $this->cacheSetExpire($type), $this->getCacheTags());
         break;
       case 'output':
         $this->storage['output'] = $this->view->display_handler->output;
         $this->gatherHeaders();
-        cache($this->table)->set($this->generateOutputKey(), $this->storage, $this->cacheSetExpire($type));
+        \Drupal::cache($this->table)->set($this->generateOutputKey(), $this->storage, $this->cacheSetExpire($type), $this->getCacheTags());
         break;
     }
   }
 
-
   /**
    * Retrieve data from the cache.
    *
@@ -151,7 +150,7 @@ public function cacheGet($type) {
       case 'results':
         // Values to set: $view->result, $view->total_rows, $view->execute_time,
         // $view->current_page.
-        if ($cache = cache($this->table)->get($this->generateResultsKey())) {
+        if ($cache = \Drupal::cache($this->table)->get($this->generateResultsKey())) {
           if (!$cutoff || $cache->created > $cutoff) {
             $this->view->result = $cache->data['result'];
             $this->view->total_rows = $cache->data['total_rows'];
@@ -162,7 +161,7 @@ public function cacheGet($type) {
         }
         return FALSE;
       case 'output':
-        if ($cache = cache($this->table)->get($this->generateOutputKey())) {
+        if ($cache = \Drupal::cache($this->table)->get($this->generateOutputKey())) {
           if (!$cutoff || $cache->created > $cutoff) {
             $this->storage = $cache->data;
             $this->view->display_handler->output = $cache->data['output'];
@@ -181,7 +180,7 @@ public function cacheGet($type) {
    * to be sure that we catch everything. Maybe that's a bad idea.
    */
   public function cacheFlush() {
-    cache($this->table)->deleteTags(array($this->view->storage->id() => TRUE));
+    Cache::invalidateTags(array($this->view->storage->id() => TRUE));
   }
 
   /**
@@ -327,6 +326,48 @@ public function generateOutputKey() {
     return $this->outputKey;
   }
 
+  /**
+   * Gets an array of cache tags for the current view.
+   *
+   * @return array
+   *   An array fo cache tags based on the current view.
+   */
+  protected function getCacheTags() {
+    $tags = array();
+
+    $entity_information = $this->view->query->getEntityInformation();
+
+    if (!empty($entity_information)) {
+      $tags[$this->view->storage->id()] = TRUE;
+      // Add an ENTITY_TYPE_view tag for each entity type used by this view.
+      foreach (array_keys($entity_information) as $type) {
+        $tags[$type . '_view'] = TRUE;
+      }
+
+      // Collect entity IDs if there are view results.
+      if (!empty($this->view->result)) {
+        foreach ($this->view->result as $result) {
+          $type = $result->_entity->entityType();
+
+          $tags[$type][] = $result->_entity->id();
+          $tags[$type . '_list_' . $result->_entity->bundle()] = TRUE;
+
+          foreach ($result->_relationship_entities as $entity) {
+            $type = $entity->entityType();
+
+            $tags[$type][] = $entity->id();
+            $tags[$type . '_list_' . $entity->bundle()] = TRUE;
+          }
+        }
+      }
+    }
+
+    // Filter out any duplicate values from generated tags.
+    return array_map(function($item) {
+      return is_array($item) ? array_unique($item) : $item;
+    }, $tags);
+  }
+
 }
 
 /**
diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/cache/Tag.php b/core/modules/views/lib/Drupal/views/Plugin/views/cache/Tag.php
new file mode 100644
index 0000000..4cad30b
--- /dev/null
+++ b/core/modules/views/lib/Drupal/views/Plugin/views/cache/Tag.php
@@ -0,0 +1,37 @@
+<?php
+
+/**
+ * @file
+ * Contains \Drupal\views\Plugin\views\cache\Tag.
+ */
+
+namespace Drupal\views\Plugin\views\cache;
+
+/**
+ * Simple caching of query results for Views displays.
+ *
+ * @ingroup views_cache_plugins
+ *
+ * @ViewsCache(
+ *   id = "tag",
+ *   title = @Translation("Tag based"),
+ *   help = @Translation("Tag based caching of data. Caches will persist until any related cache tags are invalidated.")
+ * )
+ */
+class Tag extends CachePluginBase {
+
+  /**
+   * {@inheritdoc}
+   */
+  public function summaryTitle() {
+    return t('Tag');
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  protected function cacheExpire($type) {
+    return FALSE;
+  }
+
+}
diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/query/Sql.php b/core/modules/views/lib/Drupal/views/Plugin/views/query/Sql.php
index db08a61..005e943 100644
--- a/core/modules/views/lib/Drupal/views/Plugin/views/query/Sql.php
+++ b/core/modules/views/lib/Drupal/views/Plugin/views/query/Sql.php
@@ -1247,8 +1247,8 @@ public function query($get_count = FALSE) {
 
     // Make sure each entity table has the base field added so that the
     // entities can be loaded.
-    $entity_tables = $this->getEntityTables();
-    if ($entity_tables) {
+    $entity_information = $this->getEntityInformation();
+    if ($entity_information) {
       $params = array();
       if ($groupby) {
         // Handle grouping, by retrieving the minimum entity_id.
@@ -1257,10 +1257,10 @@ public function query($get_count = FALSE) {
         );
       }
 
-      foreach ($entity_tables as $table_alias => $table) {
-        $info = entity_get_info($table['entity_type']);
-        $base_field = empty($table['revision']) ? $info['entity_keys']['id'] : $info['entity_keys']['revision'];
-        $this->addField($table_alias, $base_field, '', $params);
+      foreach ($entity_information as $entity_type => $info) {
+        $entity_info = \Drupal::entityManager()->getDefinition($entity_type);
+        $base_field = empty($table['revision']) ? $entity_info['entity_keys']['id'] : $entity_info['entity_keys']['revision'];
+        $this->addField($info['alias'], $base_field, '', $params);
       }
     }
 
@@ -1451,9 +1451,11 @@ function execute(ViewExecutable $view) {
    * Returns an array of all tables from the query that map to an entity type.
    *
    * Includes the base table and all relationships, if eligible.
+   *
    * Available keys for each table:
    * - base: The actual base table (i.e. "user" for an author relationship).
    * - relationship_id: The id of the relationship, or "none".
+   * - alias: The alias used for the relationship.
    * - entity_type: The entity type matching the base table.
    * - revision: A boolean that specifies whether the table is a base table or
    *   a revision table of the entity type.
@@ -1461,14 +1463,17 @@ function execute(ViewExecutable $view) {
    * @return array
    *   An array of table information, keyed by table alias.
    */
-  public function getEntityTables() {
+  public function getEntityInformation() {
     // Start with the base table.
     $entity_tables = array();
     $views_data = Views::viewsData();
-    $base_table_data = $views_data->get($this->view->storage->get('base_table'));
+    $base_table = $this->view->storage->get('base_table');
+    $base_table_data = $views_data->get($base_table);
+
     if (isset($base_table_data['table']['entity type'])) {
-      $entity_tables[$this->view->storage->get('base_table')] = array(
-        'base' => $this->view->storage->get('base_table'),
+      $entity_tables[$base_table_data['table']['entity type']] = array(
+        'base' => $base_table,
+        'alias' => $base_table,
         'relationship_id' => 'none',
         'entity_type' => $base_table_data['table']['entity type'],
         'revision' => FALSE,
@@ -1478,9 +1483,10 @@ public function getEntityTables() {
     foreach ($this->view->relationship as $relationship_id => $relationship) {
       $table_data = $views_data->get($relationship->definition['base']);
       if (isset($table_data['table']['entity type'])) {
-        $entity_tables[$relationship->alias] = array(
+        $entity_tables[$table_data['table']['entity type']] = array(
           'base' => $relationship->definition['base'],
           'relationship_id' => $relationship_id,
+          'alias' => $relationship->alias,
           'entity_type' => $table_data['table']['entity type'],
           'revision' => FALSE,
         );
@@ -1489,7 +1495,7 @@ public function getEntityTables() {
 
     // Determine which of the tables are revision tables.
     foreach ($entity_tables as $table_alias => $table) {
-      $info = entity_get_info($table['entity_type']);
+      $info = \Drupal::entityManager()->getDefinition($table['entity_type']);
       if (isset($info['revision table']) && $info['revision table'] == $table['base']) {
         $entity_tables[$table_alias]['revision'] = TRUE;
       }
@@ -1506,7 +1512,7 @@ public function getEntityTables() {
    * $result->_relationship_entities[$relationship_id];
    */
   function loadEntities(&$results) {
-    $entity_tables = $this->getEntityTables();
+    $entity_tables = $this->getEntityInformation();
     // No entity tables found, nothing else to do here.
     if (empty($entity_tables)) {
       return;
diff --git a/core/modules/views/lib/Drupal/views/Tests/ViewExecutableTest.php b/core/modules/views/lib/Drupal/views/Tests/ViewExecutableTest.php
index 8e16535..2fc26e2 100644
--- a/core/modules/views/lib/Drupal/views/Tests/ViewExecutableTest.php
+++ b/core/modules/views/lib/Drupal/views/Tests/ViewExecutableTest.php
@@ -2,11 +2,12 @@
 
 /**
  * @file
- * Contains \Drupal\views\Tests\ViewExecutableUnitTest.
+ * Contains \Drupal\views\Tests\ViewExecutableTest.
  */
 
 namespace Drupal\views\Tests;
 
+use Drupal\views\Views;
 use Drupal\views\ViewExecutable;
 use Drupal\views\ViewExecutableFactory;
 use Drupal\views\DisplayBag;
@@ -35,7 +36,7 @@ class ViewExecutableTest extends ViewUnitTestBase {
    *
    * @var array
    */
-  public static $testViews = array('test_destroy', 'test_executable_displays');
+  public static $testViews = array('test_destroy', 'test_executable_displays', 'test_view');
 
   /**
    * Properties that should be stored in the configuration.
@@ -435,4 +436,16 @@ public function testValidate() {
     $this->assertNotIdentical($validate, $validate_deleted, 'Master display has not been validated.');
   }
 
+  /**
+   * Tests the getEntityTypes() method.
+   */
+  public function testGetEntityTypes() {
+    // Test a view that should return no entity types.
+    $view = Views::getView('test_view');
+    $this->assertIdentical($view->getEntityTypes(), array(), 'No entity types were returned.');
+    // The base entity type (node) and relationships should be returned.
+    $view = Views::getView('test_destroy');
+    $this->assertIdentical($view->getEntityTypes(), array('node', 'comment', 'user'), 'The expected entity types were returned.');
+  }
+
 }
