diff --git a/core/core.api.php b/core/core.api.php
index 5fc58ef..20f7c7e 100644
--- a/core/core.api.php
+++ b/core/core.api.php
@@ -2367,7 +2367,7 @@ function hook_validation_constraint_alter(array &$definitions) {
  * @code
  * array('#type' => 'status_messages')
  * @endcode
- * to a render array, use drupal_render() to render it, and add a command to
+ * to a render array, use \Drupal::service(renderer)->render() to render it, and add a command to
  * place the messages in an appropriate location.
  *
  * @section sec_other Other methods for triggering Ajax
diff --git a/core/includes/common.inc b/core/includes/common.inc
index 037c5b0..5bf907e 100644
--- a/core/includes/common.inc
+++ b/core/includes/common.inc
@@ -762,7 +762,7 @@ function drupal_pre_render_link($element) {
  *
  * The purpose of this is to allow links to be logically grouped into related
  * categories, so that each child group can be rendered as its own list of
- * links if drupal_render() is called on it, but calling drupal_render() on the
+ * links if \Drupal::service(renderer)->render() is called on it, but calling \Drupal::service(renderer)->render() on the
  * parent element will still produce a single list containing all the remaining
  * links, regardless of what group they were in.
  *
@@ -887,7 +887,7 @@ function drupal_render(&$elements, $is_recursive_call = FALSE) {
  *   rendering when possible or loop through the elements and render them as
  *   they are available.
  *
- * @see drupal_render()
+ * @see \Drupal::service(renderer)->render()
  */
 function drupal_render_children(&$element, $children_keys = NULL) {
   if ($children_keys === NULL) {
@@ -941,10 +941,10 @@ function render(&$element) {
 /**
  * Hides an element from later rendering.
  *
- * The first time render() or drupal_render() is called on an element tree,
+ * The first time render() or \Drupal::service(renderer)->render() is called on an element tree,
  * as each element in the tree is rendered, it is marked with a #printed flag
  * and the rendered children of the element are cached. Subsequent calls to
- * render() or drupal_render() will not traverse the child tree of this element
+ * render() or \Drupal::service(renderer)->render() will not traverse the child tree of this element
  * again: they will just use the cached children. So if you want to hide an
  * element, be sure to call hide() on the element before its parent tree is
  * rendered for the first time, as it will have no effect on subsequent
@@ -970,10 +970,10 @@ function hide(&$element) {
  * You can also use render($element), which shows the element while rendering
  * it.
  *
- * The first time render() or drupal_render() is called on an element tree,
+ * The first time render() or \Drupal::service(renderer)->render() is called on an element tree,
  * as each element in the tree is rendered, it is marked with a #printed flag
  * and the rendered children of the element are cached. Subsequent calls to
- * render() or drupal_render() will not traverse the child tree of this element
+ * render() or \Drupal::service(renderer)->render() will not traverse the child tree of this element
  * again: they will just use the cached children. So if you want to show an
  * element, be sure to call show() on the element before its parent tree is
  * rendered for the first time, as it will have no effect on subsequent
diff --git a/core/lib/Drupal/Core/Entity/Controller/EntityListController.php b/core/lib/Drupal/Core/Entity/Controller/EntityListController.php
index d8a1ea1..1781af5 100644
--- a/core/lib/Drupal/Core/Entity/Controller/EntityListController.php
+++ b/core/lib/Drupal/Core/Entity/Controller/EntityListController.php
@@ -16,7 +16,7 @@ class EntityListController extends ControllerBase {
    *   The entity type to render.
    *
    * @return array
-   *   A render array as expected by drupal_render().
+   *   A render array as expected by \Drupal::service(renderer)->render().
    */
   public function listing($entity_type) {
     return $this->entityManager()->getListBuilder($entity_type)->render();
diff --git a/core/lib/Drupal/Core/Entity/Controller/EntityViewController.php b/core/lib/Drupal/Core/Entity/Controller/EntityViewController.php
index 983eec8..892b14d 100644
--- a/core/lib/Drupal/Core/Entity/Controller/EntityViewController.php
+++ b/core/lib/Drupal/Core/Entity/Controller/EntityViewController.php
@@ -88,7 +88,7 @@ public function buildTitle(array $page) {
    *   Defaults to 'full'.
    *
    * @return array
-   *   A render array as expected by drupal_render().
+   *   A render array as expected by \Drupal::service(renderer)->render().
    */
   public function view(EntityInterface $_entity, $view_mode = 'full') {
     $page = $this->entityManager
diff --git a/core/lib/Drupal/Core/Entity/EntityListBuilderInterface.php b/core/lib/Drupal/Core/Entity/EntityListBuilderInterface.php
index 924772d..b42ec00 100644
--- a/core/lib/Drupal/Core/Entity/EntityListBuilderInterface.php
+++ b/core/lib/Drupal/Core/Entity/EntityListBuilderInterface.php
@@ -45,7 +45,7 @@ public function getOperations(EntityInterface $entity);
    * Builds a listing of entities for the given entity type.
    *
    * @return array
-   *   A render array as expected by drupal_render().
+   *   A render array as expected by \Drupal::service(renderer)->render().
    */
   public function render();
 
diff --git a/core/lib/Drupal/Core/Entity/EntityViewBuilder.php b/core/lib/Drupal/Core/Entity/EntityViewBuilder.php
index 8bfb3a3..330b85c 100644
--- a/core/lib/Drupal/Core/Entity/EntityViewBuilder.php
+++ b/core/lib/Drupal/Core/Entity/EntityViewBuilder.php
@@ -196,7 +196,7 @@ protected function getBuildDefaults(EntityInterface $entity, $view_mode) {
    * @return array
    *   The updated renderable array.
    *
-   * @see drupal_render()
+   * @see \Drupal::service(renderer)->render()
    */
   public function build(array $build) {
     $build_list = [$build];
@@ -210,7 +210,7 @@ public function build(array $build) {
    * This function is assigned as a #pre_render callback in ::viewMultiple().
    *
    * By delaying the building of an entity until the #pre_render processing in
-   * drupal_render(), the processing cost of assembling an entity's renderable
+   * \Drupal::service(renderer)->render(), the processing cost of assembling an entity's renderable
    * array is saved on cache-hit requests.
    *
    * @param array $build_list
@@ -220,7 +220,7 @@ public function build(array $build) {
    * @return array
    *   The updated renderable array.
    *
-   * @see drupal_render()
+   * @see \Drupal::service(renderer)->render()
    */
   public function buildMultiple(array $build_list) {
     // Build the view modes and display objects.
diff --git a/core/lib/Drupal/Core/Entity/entity.api.php b/core/lib/Drupal/Core/Entity/entity.api.php
index 584cfa6..0566a45 100644
--- a/core/lib/Drupal/Core/Entity/entity.api.php
+++ b/core/lib/Drupal/Core/Entity/entity.api.php
@@ -1273,7 +1273,7 @@ function hook_entity_query_alter(\Drupal\Core\Entity\Query\QueryInterface $query
  * @param &$build
  *   A renderable array representing the entity content. The module may add
  *   elements to $build prior to rendering. The structure of $build is a
- *   renderable array as expected by drupal_render().
+ *   renderable array as expected by \Drupal::service(renderer)->render().
  * @param \Drupal\Core\Entity\EntityInterface $entity
  *   The entity object.
  * @param \Drupal\Core\Entity\Display\EntityViewDisplayInterface $display
@@ -1305,7 +1305,7 @@ function hook_entity_view(array &$build, \Drupal\Core\Entity\EntityInterface $en
  * @param &$build
  *   A renderable array representing the entity content. The module may add
  *   elements to $build prior to rendering. The structure of $build is a
- *   renderable array as expected by drupal_render().
+ *   renderable array as expected by \Drupal::service(renderer)->render().
  * @param \Drupal\Core\Entity\EntityInterface $entity
  *   The entity object.
  * @param \Drupal\Core\Entity\Display\EntityViewDisplayInterface $display
@@ -1344,7 +1344,7 @@ function hook_ENTITY_TYPE_view(array &$build, \Drupal\Core\Entity\EntityInterfac
  * the particular entity type template, if there is one (e.g., node.html.twig).
  *
  * See the @link themeable Default theme implementations topic @endlink and
- * drupal_render() for details.
+ * \Drupal::service(renderer)->render() for details.
  *
  * @param array &$build
  *   A renderable array representing the entity content.
@@ -1382,7 +1382,7 @@ function hook_entity_view_alter(array &$build, Drupal\Core\Entity\EntityInterfac
  * the particular entity type template, if there is one (e.g., node.html.twig).
  *
  * See the @link themeable Default theme implementations topic @endlink and
- * drupal_render() for details.
+ * \Drupal::service(renderer)->render() for details.
  *
  * @param array &$build
  *   A renderable array representing the entity content.
@@ -1468,7 +1468,7 @@ function hook_entity_view_mode_alter(&$view_mode, Drupal\Core\Entity\EntityInter
 }
 
 /**
- * Alter entity renderable values before cache checking in drupal_render().
+ * Alter entity renderable values before cache checking in \Drupal::service(renderer)->render().
  *
  * Invoked for a specific entity type.
  *
@@ -1483,7 +1483,7 @@ function hook_entity_view_mode_alter(&$view_mode, Drupal\Core\Entity\EntityInter
  * @param string $view_mode
  *   The view_mode that is to be used to display the entity.
  *
- * @see drupal_render()
+ * @see \Drupal::service(renderer)->render()
  * @see \Drupal\Core\Entity\EntityViewBuilder
  * @see hook_entity_build_defaults_alter()
  *
@@ -1494,7 +1494,7 @@ function hook_ENTITY_TYPE_build_defaults_alter(array &$build, \Drupal\Core\Entit
 }
 
 /**
- * Alter entity renderable values before cache checking in drupal_render().
+ * Alter entity renderable values before cache checking in \Drupal::service(renderer)->render().
  *
  * The values in the #cache key of the renderable array are used to determine if
  * a cache entry exists for the entity's rendered output. Ideally only values
@@ -1507,7 +1507,7 @@ function hook_ENTITY_TYPE_build_defaults_alter(array &$build, \Drupal\Core\Entit
  * @param string $view_mode
  *   The view_mode that is to be used to display the entity.
  *
- * @see drupal_render()
+ * @see \Drupal::service(renderer)->render()
  * @see \Drupal\Core\Entity\EntityViewBuilder
  * @see hook_ENTITY_TYPE_build_defaults_alter()
  *
diff --git a/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php b/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php
index 447b918..7ed05d1 100644
--- a/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php
+++ b/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php
@@ -17,7 +17,7 @@
 /**
  * Subscriber that wraps controllers, to handle early rendering.
  *
- * When controllers call drupal_render() (RendererInterface::render()) outside
+ * When controllers call \Drupal::service(renderer)->render() (RendererInterface::render()) outside
  * of a render context, we call that "early rendering". Controllers should
  * return only render arrays, but we cannot prevent controllers from doing early
  * rendering. The problem with early rendering is that the bubbleable metadata
@@ -36,7 +36,7 @@
  * ::renderPlain() methods. In that case, no bubbleable metadata is lost.
  *
  * If the render context is not empty, then the controller did use
- * drupal_render(), and bubbleable metadata was collected. This bubbleable
+ * \Drupal::service(renderer)->render(), and bubbleable metadata was collected. This bubbleable
  * metadata is then merged onto the render array.
  *
  * In other words: this just exists to ease the transition to Drupal 8: it
@@ -124,7 +124,7 @@ protected function wrapControllerExecutionInRenderContext($controller, array $ar
     });
 
     // If early rendering happened, i.e. if code in the controller called
-    // drupal_render() outside of a render context, then the bubbleable metadata
+    // \Drupal::service(renderer)->render() outside of a render context, then the bubbleable metadata
     // for that is stored in the current render context.
     if (!$context->isEmpty()) {
       /** @var \Drupal\Core\Render\BubbleableMetadata $early_rendering_bubbleable_metadata */
diff --git a/core/lib/Drupal/Core/Form/FormBuilderInterface.php b/core/lib/Drupal/Core/Form/FormBuilderInterface.php
index 334e10b..3557ac8 100644
--- a/core/lib/Drupal/Core/Form/FormBuilderInterface.php
+++ b/core/lib/Drupal/Core/Form/FormBuilderInterface.php
@@ -244,7 +244,7 @@ public function prepareForm($form_id, &$form, FormStateInterface &$form_state);
    * This is one of the three primary functions that recursively iterates a form
    * array. This one does it for completing the form building process. The other
    * two are self::doValidateForm() (invoked via self::validateForm() and used
-   * to invoke validation logic for each element) and drupal_render() (for
+   * to invoke validation logic for each element) and \Drupal::service(renderer)->render() (for
    * rendering each element). Each of these three pipelines provides ample
    * opportunity for modules to customize what happens. For example, during this
    * function's life cycle, the following functions get called for each element:
@@ -268,7 +268,7 @@ public function prepareForm($form_id, &$form, FormStateInterface &$form_state);
    *   called in postorder traversal, meaning they are called for the child
    *   elements first, then for the parent element.
    * There are similar properties containing callback functions invoked by
-   * self::doValidateForm() and drupal_render(), appropriate for those
+   * self::doValidateForm() and \Drupal::service(renderer)->render(), appropriate for those
    * operations.
    *
    * Developers are strongly encouraged to integrate the functionality needed by
diff --git a/core/lib/Drupal/Core/Menu/MenuLinkTree.php b/core/lib/Drupal/Core/Menu/MenuLinkTree.php
index 72e8ee9..bdda115 100644
--- a/core/lib/Drupal/Core/Menu/MenuLinkTree.php
+++ b/core/lib/Drupal/Core/Menu/MenuLinkTree.php
@@ -163,7 +163,7 @@ public function build(array $tree) {
     $tree_cacheability->applyTo($build);
 
     if ($items) {
-      // Make sure drupal_render() does not re-order the links.
+      // Make sure \Drupal::service(renderer)->render() does not re-order the links.
       $build['#sorted'] = TRUE;
       // Get the menu name from the last link.
       $item = end($items);
diff --git a/core/lib/Drupal/Core/Render/Element.php b/core/lib/Drupal/Core/Render/Element.php
index c150519..a66d8b3 100644
--- a/core/lib/Drupal/Core/Render/Element.php
+++ b/core/lib/Drupal/Core/Render/Element.php
@@ -57,7 +57,7 @@ public static function child($key) {
    * Identifies the children of an element array, optionally sorted by weight.
    *
    * The children of a element array are those key/value pairs whose key does
-   * not start with a '#'. See drupal_render() for details.
+   * not start with a '#'. See \Drupal::service(renderer)->render() for details.
    *
    * @param array $elements
    *   The element array whose children are to be identified. Passed by
diff --git a/core/lib/Drupal/Core/Render/Element/HtmlTag.php b/core/lib/Drupal/Core/Render/Element/HtmlTag.php
index 1d71350..469a869 100644
--- a/core/lib/Drupal/Core/Render/Element/HtmlTag.php
+++ b/core/lib/Drupal/Core/Render/Element/HtmlTag.php
@@ -164,7 +164,7 @@ public static function preRenderConditionalComments($element) {
     // for details.
 
     // Ensure what we are dealing with is safe.
-    // This would be done later anyway in drupal_render().
+    // This would be done later anyway in \Drupal::service(renderer)->render().
     $prefix = isset($element['#prefix']) ? $element['#prefix'] : '';
     if ($prefix && !($prefix instanceof MarkupInterface)) {
       $prefix = Xss::filterAdmin($prefix);
diff --git a/core/lib/Drupal/Core/Render/Renderer.php b/core/lib/Drupal/Core/Render/Renderer.php
index 09a1bf1..a8386d6 100644
--- a/core/lib/Drupal/Core/Render/Renderer.php
+++ b/core/lib/Drupal/Core/Render/Renderer.php
@@ -544,7 +544,7 @@ protected function doRender(&$elements, $is_root_call = FALSE) {
       $this->replacePlaceholders($elements);
       // @todo remove as part of https://www.drupal.org/node/2511330.
       if ($context->count() !== 1) {
-        throw new \LogicException('A stray drupal_render() invocation with $is_root_call = TRUE is causing bubbling of attached assets to break.');
+        throw new \LogicException('A stray \Drupal::service(renderer)->render() invocation with $is_root_call = TRUE is causing bubbling of attached assets to break.');
       }
     }
 
diff --git a/core/lib/Drupal/Core/Render/theme.api.php b/core/lib/Drupal/Core/Render/theme.api.php
index d6daa72..1e8c3e6 100644
--- a/core/lib/Drupal/Core/Render/theme.api.php
+++ b/core/lib/Drupal/Core/Render/theme.api.php
@@ -17,9 +17,9 @@
  * hierarchical arrays that include the data to be rendered into HTML (or XML or
  * another output format), and options that affect the markup. Render arrays
  * are ultimately rendered into HTML or other output formats by recursive calls
- * to drupal_render(), traversing the depth of the render array hierarchy. At
+ * to \Drupal::service(renderer)->render(), traversing the depth of the render array hierarchy. At
  * each level, the theme system is invoked to do the actual rendering. See the
- * documentation of drupal_render() and the
+ * documentation of \Drupal::service(renderer)->render() and the
  * @link theme_render Theme system and Render API topic @endlink for more
  * information about render arrays and rendering.
  *
@@ -237,13 +237,13 @@
  * hierarchical associative array containing data to be rendered and properties
  * describing how the data should be rendered. A render array that is returned
  * by a function to specify markup to be sent to the web browser or other
- * services will eventually be rendered by a call to drupal_render(), which will
+ * services will eventually be rendered by a call to \Drupal::service(renderer)->render(), which will
  * recurse through the render array hierarchy if appropriate, making calls into
  * the theme system to do the actual rendering. If a function or method actually
  * needs to return rendered output rather than a render array, the best practice
- * would be to create a render array, render it by calling drupal_render(), and
+ * would be to create a render array, render it by calling \Drupal::service(renderer)->render(), and
  * return that result, rather than writing the markup directly. See the
- * documentation of drupal_render() for more details of the rendering process.
+ * documentation of \Drupal::service(renderer)->render() for more details of the rendering process.
  *
  * Each level in the hierarchy of a render array (including the outermost array)
  * has one or more array elements. Array elements whose names start with '#' are
diff --git a/core/modules/aggregator/src/Controller/AggregatorController.php b/core/modules/aggregator/src/Controller/AggregatorController.php
index c84fb18..7a1050e 100644
--- a/core/modules/aggregator/src/Controller/AggregatorController.php
+++ b/core/modules/aggregator/src/Controller/AggregatorController.php
@@ -44,7 +44,7 @@ public static function create(ContainerInterface $container) {
    * Presents the aggregator feed creation form.
    *
    * @return array
-   *   A form array as expected by drupal_render().
+   *   A form array as expected by \Drupal::service(renderer)->render().
    */
   public function feedAdd() {
     $feed = $this->entityManager()->getStorage('aggregator_feed')
@@ -104,7 +104,7 @@ public function feedRefresh(FeedInterface $aggregator_feed) {
    * Displays the aggregator administration page.
    *
    * @return array
-   *   A render array as expected by drupal_render().
+   *   A render array as expected by \Drupal::service(renderer)->render().
    */
   public function adminOverview() {
     $entity_manager = $this->entityManager();
diff --git a/core/modules/block/block.api.php b/core/modules/block/block.api.php
index 2d61bb0..fb9877c 100644
--- a/core/modules/block/block.api.php
+++ b/core/modules/block/block.api.php
@@ -72,7 +72,7 @@
  * If the module wishes to act on the rendered HTML of the block rather than
  * the structured content array, it may use this hook to add a #post_render
  * callback. Alternatively, it could also implement hook_preprocess_HOOK() for
- * block.html.twig. See drupal_render() documentation or the
+ * block.html.twig. See \Drupal::service(renderer)->render() documentation or the
  * @link themeable Default theme implementations topic @endlink for details.
  *
  * In addition to hook_block_view_alter(), which is called for all blocks, there
diff --git a/core/modules/block/src/Controller/BlockListController.php b/core/modules/block/src/Controller/BlockListController.php
index 74ea9c1..e4a869c 100644
--- a/core/modules/block/src/Controller/BlockListController.php
+++ b/core/modules/block/src/Controller/BlockListController.php
@@ -48,7 +48,7 @@ public static function create(ContainerInterface $container) {
    *   The current request.
    *
    * @return array
-   *   A render array as expected by drupal_render().
+   *   A render array as expected by \Drupal::service(renderer)->render().
    */
   public function listing($theme = NULL, Request $request = NULL) {
     $theme = $theme ?: $this->config('system.theme')->get('default');
diff --git a/core/modules/block_content/src/Controller/BlockContentController.php b/core/modules/block_content/src/Controller/BlockContentController.php
index 1caad74..a4716f1 100644
--- a/core/modules/block_content/src/Controller/BlockContentController.php
+++ b/core/modules/block_content/src/Controller/BlockContentController.php
@@ -98,7 +98,7 @@ public function add(Request $request) {
    *   The current request object.
    *
    * @return array
-   *   A form array as expected by drupal_render().
+   *   A form array as expected by \Drupal::service(renderer)->render().
    */
   public function addForm(BlockContentTypeInterface $block_content_type, Request $request) {
     $block = $this->blockContentStorage->create(array(
diff --git a/core/modules/book/src/BookManager.php b/core/modules/book/src/BookManager.php
index 2942462..3664710 100644
--- a/core/modules/book/src/BookManager.php
+++ b/core/modules/book/src/BookManager.php
@@ -504,7 +504,7 @@ public function bookTreeOutput(array $tree) {
     $build = [];
 
     if ($items) {
-      // Make sure drupal_render() does not re-order the links.
+      // Make sure \Drupal::service(renderer)->render() does not re-order the links.
       $build['#sorted'] = TRUE;
       // Get the book id from the last link.
       $item = end($items);
diff --git a/core/modules/book/src/BookManagerInterface.php b/core/modules/book/src/BookManagerInterface.php
index fd3cfc1..839423a 100644
--- a/core/modules/book/src/BookManagerInterface.php
+++ b/core/modules/book/src/BookManagerInterface.php
@@ -247,7 +247,7 @@ public function deleteFromBook($nid);
    *   A data structure representing the tree as returned from buildBookOutlineData.
    *
    * @return array
-   *   A structured array to be rendered by drupal_render().
+   *   A structured array to be rendered by \Drupal::service(renderer)->render().
    *
    * @see \Drupal\Core\Menu\MenuLinkTree::build
    */
diff --git a/core/modules/comment/comment.module b/core/modules/comment/comment.module
index 40b4e40..e9194d0 100644
--- a/core/modules/comment/comment.module
+++ b/core/modules/comment/comment.module
@@ -252,7 +252,7 @@ function comment_node_view_alter(array &$build, EntityInterface $node, EntityVie
  *   content language of the current request.
  *
  * @return array
- *   An array as expected by drupal_render().
+ *   An array as expected by \Drupal::service(renderer)->render().
  *
  * @deprecated in Drupal 8.x and will be removed before Drupal 9.0.
  *   Use \Drupal::entityManager()->getViewBuilder('comment')->view().
@@ -275,12 +275,12 @@ function comment_view(CommentInterface $comment, $view_mode = 'full', $langcode
  *   Defaults to NULL.
  *
  * @return array
- *   An array in the format expected by drupal_render().
+ *   An array in the format expected by \Drupal::service(renderer)->render().
  *
  * @deprecated in Drupal 8.x and will be removed before Drupal 9.0.
  *   Use \Drupal::entityManager()->getViewBuilder('comment')->viewMultiple().
  *
- * @see drupal_render()
+ * @see \Drupal::service(renderer)->render()
  */
 function comment_view_multiple($comments, $view_mode = 'full', $langcode = NULL) {
   return entity_view_multiple($comments, $view_mode, $langcode);
@@ -555,7 +555,7 @@ function comment_user_predelete($account) {
  *   The current state of the form.
  *
  * @return array
- *   An array as expected by drupal_render().
+ *   An array as expected by \Drupal::service(renderer)->render().
  */
 function comment_preview(CommentInterface $comment, FormStateInterface $form_state) {
   $preview_build = array();
diff --git a/core/modules/config_translation/src/Controller/ConfigTranslationListController.php b/core/modules/config_translation/src/Controller/ConfigTranslationListController.php
index 7a39289..8ea25a7 100644
--- a/core/modules/config_translation/src/Controller/ConfigTranslationListController.php
+++ b/core/modules/config_translation/src/Controller/ConfigTranslationListController.php
@@ -45,7 +45,7 @@ public static function create(ContainerInterface $container) {
    *   The name of the mapper.
    *
    * @return array
-   *   A render array as expected by drupal_render().
+   *   A render array as expected by \Drupal::service(renderer)->render().
    *
    * @throws \Symfony\Component\HttpKernel\Exception\NotFoundHttpException
    *   Throws an exception if a mapper plugin could not be instantiated from the
diff --git a/core/modules/contact/src/Controller/ContactController.php b/core/modules/contact/src/Controller/ContactController.php
index 4d46f83..22b4e57 100644
--- a/core/modules/contact/src/Controller/ContactController.php
+++ b/core/modules/contact/src/Controller/ContactController.php
@@ -47,7 +47,7 @@ public static function create(ContainerInterface $container) {
    *   The contact form to use.
    *
    * @return array
-   *   The form as render array as expected by drupal_render().
+   *   The form as render array as expected by \Drupal::service(renderer)->render().
    *
    * @throws \Symfony\Component\HttpKernel\Exception\NotFoundHttpException
    *   Exception is thrown when user tries to access non existing default
@@ -94,7 +94,7 @@ public function contactSitePage(ContactFormInterface $contact_form = NULL) {
    *   The account for which a personal contact form should be generated.
    *
    * @return array
-   *   The personal contact form as render array as expected by drupal_render().
+   *   The personal contact form as render array as expected by \Drupal::service(renderer)->render().
    *
    * @throws \Symfony\Component\HttpKernel\Exception\NotFoundHttpException
    *   Exception is thrown when user tries to access a contact form for a
diff --git a/core/modules/contextual/src/Element/ContextualLinks.php b/core/modules/contextual/src/Element/ContextualLinks.php
index 8f67023..d599d14 100644
--- a/core/modules/contextual/src/Element/ContextualLinks.php
+++ b/core/modules/contextual/src/Element/ContextualLinks.php
@@ -86,7 +86,7 @@ public static function preRenderLinks(array $element) {
     // Allow modules to alter the renderable contextual links element.
     static::moduleHandler()->alter('contextual_links_view', $element, $items);
 
-    // If there are no links, tell drupal_render() to abort rendering.
+    // If there are no links, tell \Drupal::service(renderer)->render() to abort rendering.
     if (empty($element['#links'])) {
       $element['#printed'] = TRUE;
     }
diff --git a/core/modules/dblog/src/Controller/DbLogController.php b/core/modules/dblog/src/Controller/DbLogController.php
index 12483a4..bb2eeaa 100644
--- a/core/modules/dblog/src/Controller/DbLogController.php
+++ b/core/modules/dblog/src/Controller/DbLogController.php
@@ -112,7 +112,7 @@ public static function getLogLevelClassMap() {
    * Full-length messages can be viewed on the message details page.
    *
    * @return array
-   *   A render array as expected by drupal_render().
+   *   A render array as expected by \Drupal::service(renderer)->render().
    *
    * @see dblog_clear_log_form()
    * @see dblog_event()
@@ -233,7 +233,7 @@ public function overview() {
    *
    * @return array
    *   If the ID is located in the Database Logging table, a build array in the
-   *   format expected by drupal_render();
+   *   format expected by \Drupal::service(renderer)->render();
    */
   public function eventDetails($event_id) {
     $build = array();
@@ -371,7 +371,7 @@ public function formatMessage($row) {
    *   Type of database log events to display (e.g., 'search').
    *
    * @return array
-   *   A build array in the format expected by drupal_render().
+   *   A build array in the format expected by \Drupal::service(renderer)->render().
    */
   public function topLogMessages($type) {
     $header = array(
diff --git a/core/modules/field_ui/src/Controller/FieldConfigListController.php b/core/modules/field_ui/src/Controller/FieldConfigListController.php
index 0a6911a..ccf71d4 100644
--- a/core/modules/field_ui/src/Controller/FieldConfigListController.php
+++ b/core/modules/field_ui/src/Controller/FieldConfigListController.php
@@ -21,7 +21,7 @@ class FieldConfigListController extends EntityListController {
    *   The current route match.
    *
    * @return array
-   *   A render array as expected by drupal_render().
+   *   A render array as expected by \Drupal::service(renderer)->render().
    */
   public function listing($entity_type_id = NULL, $bundle = NULL, RouteMatchInterface $route_match = NULL) {
     return $this->entityManager()->getListBuilder('field_config')->render($entity_type_id, $bundle);
diff --git a/core/modules/field_ui/src/Element/FieldUiTable.php b/core/modules/field_ui/src/Element/FieldUiTable.php
index 05d5d04..f8e823d 100644
--- a/core/modules/field_ui/src/Element/FieldUiTable.php
+++ b/core/modules/field_ui/src/Element/FieldUiTable.php
@@ -38,7 +38,7 @@ public function getInfo() {
    * @return array
    *   The $element with prepared variables ready for field-ui-table.html.twig.
    *
-   * @see drupal_render()
+   * @see \Drupal::service(renderer)->render()
    * @see \Drupal\Core\Render\Element\Table::preRenderTable()
    */
   public static function tablePreRender($elements) {
diff --git a/core/modules/field_ui/src/Form/EntityDisplayFormBase.php b/core/modules/field_ui/src/Form/EntityDisplayFormBase.php
index cfa5c39..2618755 100644
--- a/core/modules/field_ui/src/Form/EntityDisplayFormBase.php
+++ b/core/modules/field_ui/src/Form/EntityDisplayFormBase.php
@@ -678,7 +678,7 @@ public function multistepAjax($form, FormStateInterface $form_state) {
    *
    * @return array
    *
-   * @see drupal_render()
+   * @see \Drupal::service(renderer)->render()
    * @see \Drupal\Core\Render\Element\Table::preRenderTable()
    *
    * @deprecated in Drupal 8.0.0, will be removed before Drupal 9.0.0.
diff --git a/core/modules/help/src/Controller/HelpController.php b/core/modules/help/src/Controller/HelpController.php
index 6c3f061..84b75bc 100644
--- a/core/modules/help/src/Controller/HelpController.php
+++ b/core/modules/help/src/Controller/HelpController.php
@@ -107,7 +107,7 @@ public function helpMain() {
    *   A module name to display a help page for.
    *
    * @return array
-   *   A render array as expected by drupal_render().
+   *   A render array as expected by \Drupal::service(renderer)->render().
    *
    * @throws \Symfony\Component\HttpKernel\Exception\NotFoundHttpException
    */
diff --git a/core/modules/image/src/Tests/ImageDimensionsTest.php b/core/modules/image/src/Tests/ImageDimensionsTest.php
index 6f73042..1b3d52b 100644
--- a/core/modules/image/src/Tests/ImageDimensionsTest.php
+++ b/core/modules/image/src/Tests/ImageDimensionsTest.php
@@ -277,9 +277,9 @@ function testImageDimensions() {
   /**
    * Render an image style element.
    *
-   * drupal_render() alters the passed $variables array by adding a new key
+   * \Drupal::service(renderer)->render() alters the passed $variables array by adding a new key
    * '#printed' => TRUE. This prevents next call to re-render the element. We
-   * wrap drupal_render() in a helper protected method and pass each time a
+   * wrap \Drupal::service(renderer)->render() in a helper protected method and pass each time a
    * fresh array so that $variables won't get altered and the element is
    * re-rendered each time.
    */
diff --git a/core/modules/node/node.admin.inc b/core/modules/node/node.admin.inc
index d6ffd10..4f4b8d8 100644
--- a/core/modules/node/node.admin.inc
+++ b/core/modules/node/node.admin.inc
@@ -172,7 +172,7 @@ function _node_mass_update_batch_finished($success, $results, $operations) {
       '#theme' => 'item_list',
       '#items' => $results,
     );
-    $message .= drupal_render($item_list);
+    $message .= \Drupal::service('renderer')->render($item_list);
     drupal_set_message($message);
   }
 }
diff --git a/core/modules/node/node.module b/core/modules/node/node.module
index fa9d3e9..1fce6ab 100644
--- a/core/modules/node/node.module
+++ b/core/modules/node/node.module
@@ -578,9 +578,10 @@ function template_preprocess_node(&$variables) {
   $variables['node'] = $variables['elements']['#node'];
   /** @var \Drupal\node\NodeInterface $node */
   $node = $variables['node'];
-  $variables['date'] = drupal_render($variables['elements']['created']);
+  $renderer = \Drupal::service('renderer');
+  $variables['date'] = $renderer->render($variables['elements']['created']);
   unset($variables['elements']['created']);
-  $variables['author_name'] = drupal_render($variables['elements']['uid']);
+  $variables['author_name'] = $renderer->render($variables['elements']['uid']);
   unset($variables['elements']['uid']);
 
   $variables['url'] = $node->url('canonical', array(
@@ -778,14 +779,14 @@ function node_get_recent($number = 10) {
  *   the global content language of the current request.
  *
  * @return array
- *   An array as expected by drupal_render().
+ *   An array as expected by \Drupal::service(renderer)->render().
  */
 function node_view(NodeInterface $node, $view_mode = 'full', $langcode = NULL) {
   return entity_view($node, $view_mode, $langcode);
 }
 
 /**
- * Constructs a drupal_render() style array from an array of loaded nodes.
+ * Constructs a \Drupal::service(renderer)->render() style array from an array of loaded nodes.
  *
  * @param $nodes
  *   An array of nodes as returned by Node::loadMultiple().
@@ -796,7 +797,7 @@ function node_view(NodeInterface $node, $view_mode = 'full', $langcode = NULL) {
  *   content language of the current request.
  *
  * @return array
- *   An array in the format expected by drupal_render().
+ *   An array in the format expected by \Drupal::service(renderer)->render().
  */
 function node_view_multiple($nodes, $view_mode = 'teaser', $langcode = NULL) {
   return entity_view_multiple($nodes, $view_mode, $langcode);
diff --git a/core/modules/node/src/Controller/NodeController.php b/core/modules/node/src/Controller/NodeController.php
index 8fd04b6..986f2a3 100644
--- a/core/modules/node/src/Controller/NodeController.php
+++ b/core/modules/node/src/Controller/NodeController.php
@@ -121,7 +121,7 @@ public function add(NodeTypeInterface $node_type) {
    *   The node revision ID.
    *
    * @return array
-   *   An array suitable for drupal_render().
+   *   An array suitable for \Drupal::service(renderer)->render().
    */
   public function revisionShow($node_revision) {
     $node = $this->entityManager()->getStorage('node')->loadRevision($node_revision);
@@ -152,7 +152,7 @@ public function revisionPageTitle($node_revision) {
    *   A node object.
    *
    * @return array
-   *   An array as expected by drupal_render().
+   *   An array as expected by \Drupal::service(renderer)->render().
    */
   public function revisionOverview(NodeInterface $node) {
     $account = $this->currentUser();
diff --git a/core/modules/node/src/NodeListBuilder.php b/core/modules/node/src/NodeListBuilder.php
index 921ac9f..87247f0 100644
--- a/core/modules/node/src/NodeListBuilder.php
+++ b/core/modules/node/src/NodeListBuilder.php
@@ -8,6 +8,7 @@
 use Drupal\Core\Entity\EntityStorageInterface;
 use Drupal\Core\Entity\EntityTypeInterface;
 use Drupal\Core\Language\LanguageInterface;
+use Drupal\Core\Render\RendererInterface;
 use Drupal\Core\Routing\RedirectDestinationInterface;
 use Symfony\Component\DependencyInjection\ContainerInterface;
 
@@ -33,6 +34,13 @@ class NodeListBuilder extends EntityListBuilder {
   protected $redirectDestination;
 
   /**
+   * The renderer.
+   *
+   * @var \Drupal\Core\Render\RendererInterface
+   */
+  protected $renderer;
+
+  /**
    * Constructs a new NodeListBuilder object.
    *
    * @param \Drupal\Core\Entity\EntityTypeInterface $entity_type
@@ -44,11 +52,12 @@ class NodeListBuilder extends EntityListBuilder {
    * @param \Drupal\Core\Routing\RedirectDestinationInterface $redirect_destination
    *   The redirect destination service.
    */
-  public function __construct(EntityTypeInterface $entity_type, EntityStorageInterface $storage, DateFormatterInterface $date_formatter, RedirectDestinationInterface $redirect_destination) {
-    parent::__construct($entity_type, $storage);
+  public function __construct(EntityTypeInterface $entity_type, EntityStorageInterface $storage, DateFormatterInterface $date_formatter, RedirectDestinationInterface $redirect_destination, RendererInterface $renderer) {
+parent::__construct($entity_type, $storage);
 
     $this->dateFormatter = $date_formatter;
     $this->redirectDestination = $redirect_destination;
+    $this->renderer = $renderer;
   }
 
   /**
@@ -59,7 +68,8 @@ public static function createInstance(ContainerInterface $container, EntityTypeI
       $entity_type,
       $container->get('entity.manager')->getStorage($entity_type->id()),
       $container->get('date.formatter'),
-      $container->get('redirect.destination')
+      $container->get('redirect.destination'),
+      $container->get('renderer')
     );
   }
 
@@ -110,7 +120,7 @@ public function buildRow(EntityInterface $entity) {
     $row['title']['data'] = array(
       '#type' => 'link',
       '#title' => $entity->label(),
-      '#suffix' => ' ' . drupal_render($mark),
+      '#suffix' => ' ' . $this->renderer->render($mark),
       '#url' => $uri,
     );
     $row['type'] = node_get_type_label($entity);
diff --git a/core/modules/node/src/Plugin/Action/UnpublishByKeywordNode.php b/core/modules/node/src/Plugin/Action/UnpublishByKeywordNode.php
index 6ec835e..5fdd684 100644
--- a/core/modules/node/src/Plugin/Action/UnpublishByKeywordNode.php
+++ b/core/modules/node/src/Plugin/Action/UnpublishByKeywordNode.php
@@ -5,7 +5,10 @@
 use Drupal\Component\Utility\Tags;
 use Drupal\Core\Action\ConfigurableActionBase;
 use Drupal\Core\Form\FormStateInterface;
+use Drupal\Core\Plugin\ContainerFactoryPluginInterface;
 use Drupal\Core\Session\AccountInterface;
+use Drupal\Core\Render\RendererInterface;
+use Symfony\Component\DependencyInjection\ContainerInterface;
 
 /**
  * Unpublishes a node containing certain keywords.
@@ -16,7 +19,43 @@
  *   type = "node"
  * )
  */
-class UnpublishByKeywordNode extends ConfigurableActionBase {
+class UnpublishByKeywordNode extends ConfigurableActionBase implements ContainerFactoryPluginInterface{
+
+  /**
+   * The renderer.
+   *
+   * @var \Drupal\Core\Render\RendererInterface
+   */
+  protected $renderer;
+
+  /**
+   * Constructs a UnpublishByKeywordNode object.
+   *
+   * @param array $configuration
+   *   A configuration array containing information about the plugin instance.
+   * @param string $plugin_id
+   *   The plugin ID for the plugin instance.
+   * @param mixed $plugin_definition
+   *   The plugin implementation definition.
+   * @param \Drupal\Core\Render\RendererInterface $renderer
+   *   The renderer.
+   */
+  public function __construct(array $configuration, $plugin_id, $plugin_definition, RendererInterface $renderer) {
+    parent::__construct($configuration, $plugin_id, $plugin_definition);
+    $this->renderer = $renderer;
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) {
+    return new static(
+      $configuration,
+      $plugin_id,
+      $plugin_definition,
+      $container->get('renderer')
+    );
+  }
 
   /**
    * {@inheritdoc}
@@ -24,7 +63,7 @@ class UnpublishByKeywordNode extends ConfigurableActionBase {
   public function execute($node = NULL) {
     foreach ($this->configuration['keywords'] as $keyword) {
       $elements = node_view(clone $node);
-      if (strpos(drupal_render($elements), $keyword) !== FALSE || strpos($node->label(), $keyword) !== FALSE) {
+      if (strpos($this->renderer->render($elements), $keyword) !== FALSE || strpos($node->label(), $keyword) !== FALSE) {
         $node->setPublished(FALSE);
         $node->save();
         break;
diff --git a/core/modules/path/src/Controller/PathController.php b/core/modules/path/src/Controller/PathController.php
index 26b5d76..b5c95ab 100644
--- a/core/modules/path/src/Controller/PathController.php
+++ b/core/modules/path/src/Controller/PathController.php
@@ -59,7 +59,7 @@ public static function create(ContainerInterface $container) {
    *   The request object.
    *
    * @return array
-   *   A render array as expected by drupal_render().
+   *   A render array as expected by \Drupal::service(renderer)->render().
    */
   public function adminOverview(Request $request) {
     $keys = $request->query->get('search');
diff --git a/core/modules/simpletest/src/WebTestBase.php b/core/modules/simpletest/src/WebTestBase.php
index eb1ad73..860eee0 100644
--- a/core/modules/simpletest/src/WebTestBase.php
+++ b/core/modules/simpletest/src/WebTestBase.php
@@ -243,7 +243,7 @@ function __construct($test_id = NULL) {
    *
    * Entities postpone the composition of their renderable arrays to #pre_render
    * functions in order to maximize cache efficacy. This means that the full
-   * renderable array for an entity is constructed in drupal_render(). Some
+   * renderable array for an entity is constructed in \Drupal::service(renderer)->render(). Some
    * tests require the complete renderable array for an entity outside of the
    * drupal_render process in order to verify the presence of specific values.
    * This method isolates the steps in the render process that produce an
@@ -260,7 +260,7 @@ function __construct($test_id = NULL) {
    *   (optional) Whether to clear the cache for this entity.
    * @return array
    *
-   * @see drupal_render()
+   * @see \Drupal::service(renderer)->render()
    */
   protected function drupalBuildEntityView(EntityInterface $entity, $view_mode = 'full', $langcode = NULL, $reset = FALSE) {
     $ensure_fully_built = function(&$elements) use (&$ensure_fully_built) {
diff --git a/core/modules/system/src/Tests/Common/RenderElementTypesTest.php b/core/modules/system/src/Tests/Common/RenderElementTypesTest.php
index e60bb52..0df0a64 100644
--- a/core/modules/system/src/Tests/Common/RenderElementTypesTest.php
+++ b/core/modules/system/src/Tests/Common/RenderElementTypesTest.php
@@ -7,7 +7,7 @@
 use Drupal\simpletest\KernelTestBase;
 
 /**
- * Tests the markup of core render element types passed to drupal_render().
+ * Tests the markup of core render element types passed to \Drupal::service(renderer)->render().
  *
  * @group Common
  */
@@ -190,7 +190,7 @@ function testMoreLink() {
     foreach ($elements as $element) {
       $xml = new \SimpleXMLElement(\Drupal::service('renderer')->renderRoot($element['value']));
       $result = $xml->xpath($element['expected']);
-      $this->assertTrue($result, '"' . $element['name'] . '" input rendered correctly by drupal_render().');
+      $this->assertTrue($result, '"' . $element['name'] . '" input rendered correctly by \Drupal::service(renderer)->render().');
     }
   }
 
@@ -221,7 +221,7 @@ function testSystemCompactLink() {
     foreach ($elements as $element) {
       $xml = new \SimpleXMLElement(\Drupal::service('renderer')->renderRoot($element['value']));
       $result = $xml->xpath($element['expected']);
-      $this->assertTrue($result, '"' . $element['name'] . '" is rendered correctly by drupal_render().');
+      $this->assertTrue($result, '"' . $element['name'] . '" is rendered correctly by \Drupal::service(renderer)->render().');
     }
 
     // Set admin compact mode on for additional tests.
@@ -237,7 +237,7 @@ function testSystemCompactLink() {
 
     $xml = new \SimpleXMLElement(\Drupal::service('renderer')->renderRoot($element['value']));
     $result = $xml->xpath($element['expected']);
-    $this->assertTrue($result, '"' . $element['name'] . '" is rendered correctly by drupal_render().');
+    $this->assertTrue($result, '"' . $element['name'] . '" is rendered correctly by \Drupal::service(renderer)->render().');
   }
 
 }
diff --git a/core/modules/system/src/Tests/Common/RenderTest.php b/core/modules/system/src/Tests/Common/RenderTest.php
index 1eee23e..6a70d14 100644
--- a/core/modules/system/src/Tests/Common/RenderTest.php
+++ b/core/modules/system/src/Tests/Common/RenderTest.php
@@ -5,7 +5,7 @@
 use Drupal\simpletest\KernelTestBase;
 
 /**
- * Performs functional tests on drupal_render().
+ * Performs functional tests on \Drupal::service(renderer)->render().
  *
  * @group Common
  */
diff --git a/core/modules/system/src/Tests/Common/RenderWebTest.php b/core/modules/system/src/Tests/Common/RenderWebTest.php
index fde7fa6..7ab6070 100644
--- a/core/modules/system/src/Tests/Common/RenderWebTest.php
+++ b/core/modules/system/src/Tests/Common/RenderWebTest.php
@@ -8,7 +8,7 @@
 use Drupal\simpletest\WebTestBase;
 
 /**
- * Performs integration tests on drupal_render().
+ * Performs integration tests on \Drupal::service(renderer)->render().
  *
  * @group Common
  */
diff --git a/core/modules/system/src/Tests/Theme/ThemeTest.php b/core/modules/system/src/Tests/Theme/ThemeTest.php
index 4eae7ae..7cce65d 100644
--- a/core/modules/system/src/Tests/Theme/ThemeTest.php
+++ b/core/modules/system/src/Tests/Theme/ThemeTest.php
@@ -237,7 +237,7 @@ function testDrupalRenderChildren() {
         '#markup' => 'Foo',
       ),
     );
-    $this->assertThemeOutput('theme_test_render_element_children', $element, 'Foo', 'drupal_render() avoids #theme recursion loop when rendering a render element.');
+    $this->assertThemeOutput('theme_test_render_element_children', $element, 'Foo', '\Drupal::service(renderer)->render() avoids #theme recursion loop when rendering a render element.');
 
     $element = array(
       '#theme_wrappers' => array('theme_test_render_element_children'),
@@ -245,7 +245,7 @@ function testDrupalRenderChildren() {
         '#markup' => 'Foo',
       ),
     );
-    $this->assertThemeOutput('theme_test_render_element_children', $element, 'Foo', 'drupal_render() avoids #theme_wrappers recursion loop when rendering a render element.');
+    $this->assertThemeOutput('theme_test_render_element_children', $element, 'Foo', '\Drupal::service(renderer)->render() avoids #theme_wrappers recursion loop when rendering a render element.');
   }
 
   /**
diff --git a/core/modules/system/tests/modules/common_test/common_test.module b/core/modules/system/tests/modules/common_test/common_test.module
index 0633ac8..44502fb 100644
--- a/core/modules/system/tests/modules/common_test/common_test.module
+++ b/core/modules/system/tests/modules/common_test/common_test.module
@@ -129,7 +129,7 @@ function common_test_theme() {
 }
 
 /**
- * Provides a theme function for drupal_render().
+ * Provides a theme function for \Drupal::service(renderer)->render().
  */
 function theme_common_test_foo($variables) {
   return $variables['foo'] . $variables['bar'];
diff --git a/core/modules/system/tests/modules/test_page_test/src/Controller/Test.php b/core/modules/system/tests/modules/test_page_test/src/Controller/Test.php
index 35ccf0c..5987c88 100644
--- a/core/modules/system/tests/modules/test_page_test/src/Controller/Test.php
+++ b/core/modules/system/tests/modules/test_page_test/src/Controller/Test.php
@@ -12,7 +12,7 @@ class Test {
    * Renders a page with a title.
    *
    * @return array
-   *   A render array as expected by drupal_render()
+   *   A render array as expected by \Drupal::service(renderer)->render()
    */
   public function renderTitle() {
     $build = array();
@@ -26,7 +26,7 @@ public function renderTitle() {
    * Renders a page.
    *
    * @return array
-   *   A render array as expected by drupal_render().
+   *   A render array as expected by \Drupal::service(renderer)->render().
    */
   public function staticTitle() {
     $build = array();
@@ -63,7 +63,7 @@ public function controllerWithCache() {
    * Returns a generic page render array for title tests.
    *
    * @return array
-   *   A render array as expected by drupal_render()
+   *   A render array as expected by \Drupal::service(renderer)->render()
    */
   public function renderPage() {
     return array(
diff --git a/core/modules/system/tests/modules/theme_test/theme_test.module b/core/modules/system/tests/modules/theme_test/theme_test.module
index 540185e..cd9eb71 100644
--- a/core/modules/system/tests/modules/theme_test/theme_test.module
+++ b/core/modules/system/tests/modules/theme_test/theme_test.module
@@ -141,10 +141,10 @@ function template_preprocess_theme_test_render_element(&$variables) {
 }
 
 /**
- * Theme function for testing rendering of child elements via drupal_render().
+ * Theme function for testing rendering of child elements via \Drupal::service(renderer)->render().
  *
  * Theme hooks defining a 'render element' add an internal '#render_children'
- * property. When this property is found, drupal_render() avoids calling
+ * property. When this property is found, \Drupal::service(renderer)->render() avoids calling
  * the 'theme.manager' service 'render' method on the top-level element to
  * prevent infinite recursion.
  *
diff --git a/core/modules/taxonomy/taxonomy.module b/core/modules/taxonomy/taxonomy.module
index 30a9ca2..4da0094 100644
--- a/core/modules/taxonomy/taxonomy.module
+++ b/core/modules/taxonomy/taxonomy.module
@@ -185,14 +185,14 @@ function taxonomy_check_vocabulary_hierarchy(VocabularyInterface $vocabulary, $c
  *   content language of the current request.
  *
  * @return array
- *   A $page element suitable for use by drupal_render().
+ *   A $page element suitable for use by \Drupal::service(renderer)->render().
  */
 function taxonomy_term_view(Term $term, $view_mode = 'full', $langcode = NULL) {
   return entity_view($term, $view_mode, $langcode);
 }
 
 /**
- * Constructs a drupal_render() style array from an array of loaded terms.
+ * Constructs a \Drupal::service(renderer)->render() style array from an array of loaded terms.
  *
  * @param array $terms
  *   An array of taxonomy terms as returned by Term::loadMultiple().
@@ -203,7 +203,7 @@ function taxonomy_term_view(Term $term, $view_mode = 'full', $langcode = NULL) {
  *   content language of the current request.
  *
  * @return array
- *   An array in the format expected by drupal_render().
+ *   An array in the format expected by \Drupal::service(renderer)->render().
  */
 function taxonomy_term_view_multiple(array $terms, $view_mode = 'full', $langcode = NULL) {
   return entity_view_multiple($terms, $view_mode, $langcode);
diff --git a/core/modules/toolbar/src/Element/Toolbar.php b/core/modules/toolbar/src/Element/Toolbar.php
index 7077372..ba81c6f 100644
--- a/core/modules/toolbar/src/Element/Toolbar.php
+++ b/core/modules/toolbar/src/Element/Toolbar.php
@@ -50,7 +50,7 @@ public function getInfo() {
   }
 
   /**
-   * Builds the Toolbar as a structured array ready for drupal_render().
+   * Builds the Toolbar as a structured array ready for \Drupal::service(renderer)->render().
    *
    * Since building the toolbar takes some time, it is done just prior to
    * rendering to ensure that it is built only if it will be displayed.
diff --git a/core/modules/toolbar/toolbar.module b/core/modules/toolbar/toolbar.module
index 281f3ab..d21bcbc 100644
--- a/core/modules/toolbar/toolbar.module
+++ b/core/modules/toolbar/toolbar.module
@@ -217,7 +217,7 @@ function toolbar_toolbar() {
  * @return array
  *   The updated renderable array.
  *
- * @see drupal_render()
+ * @see \Drupal::service(renderer)->render()
  */
 function toolbar_prerender_toolbar_administration_tray(array $element) {
   $menu_tree = \Drupal::service('toolbar.menu_tree');
diff --git a/core/modules/user/user.module b/core/modules/user/user.module
index 1e84fa9..9cb72eb 100644
--- a/core/modules/user/user.module
+++ b/core/modules/user/user.module
@@ -878,14 +878,14 @@ function user_delete_multiple(array $uids) {
  *   content language of the current request.
  *
  * @return array
- *   An array as expected by drupal_render().
+ *   An array as expected by \Drupal::service(renderer)->render().
  */
 function user_view($account, $view_mode = 'full', $langcode = NULL) {
   return entity_view($account, $view_mode, $langcode);
 }
 
 /**
- * Constructs a drupal_render() style array from an array of loaded users.
+ * Constructs a \Drupal::service(renderer)->render() style array from an array of loaded users.
  *
  * @param \Drupal\user\UserInterface[] $accounts
  *   An array of user accounts as returned by User::loadMultiple().
@@ -896,7 +896,7 @@ function user_view($account, $view_mode = 'full', $langcode = NULL) {
  *   content language of the current request.
  *
  * @return array
- *   An array in the format expected by drupal_render().
+ *   An array in the format expected by \Drupal::service(renderer)->render().
  */
 function user_view_multiple($accounts, $view_mode = 'full', $langcode = NULL) {
   return entity_view_multiple($accounts, $view_mode, $langcode);
diff --git a/core/modules/views/src/Plugin/views/field/FieldHandlerInterface.php b/core/modules/views/src/Plugin/views/field/FieldHandlerInterface.php
index d1115a9..c91131f 100644
--- a/core/modules/views/src/Plugin/views/field/FieldHandlerInterface.php
+++ b/core/modules/views/src/Plugin/views/field/FieldHandlerInterface.php
@@ -255,7 +255,7 @@ public function renderText($alter);
   public function getRenderTokens($item);
 
   /**
-   * Passes values to drupal_render() using $this->themeFunctions() as #theme.
+   * Passes values to \Drupal::service(renderer)->render() using $this->themeFunctions() as #theme.
    *
    * @param \Drupal\views\ResultRow $values
    *   Holds single row of a view's result set.
diff --git a/core/modules/views/views.module b/core/modules/views/views.module
index e1a4d8c..1787989 100644
--- a/core/modules/views/views.module
+++ b/core/modules/views/views.module
@@ -322,7 +322,7 @@ function views_theme_suggestions_container_alter(array &$suggestions, array $var
  *
  * @param $render_element
  *   The renderable array to which contextual links will be added. This array
- *   should be suitable for passing in to drupal_render() and will normally
+ *   should be suitable for passing in to \Drupal::service(renderer)->render() and will normally
  *   contain a representation of the view display whose contextual links are
  *   being requested.
  * @param $location
diff --git a/core/tests/Drupal/KernelTests/Core/Entity/EntityViewBuilderTest.php b/core/tests/Drupal/KernelTests/Core/Entity/EntityViewBuilderTest.php
index 1c3a310..a55a7f5 100644
--- a/core/tests/Drupal/KernelTests/Core/Entity/EntityViewBuilderTest.php
+++ b/core/tests/Drupal/KernelTests/Core/Entity/EntityViewBuilderTest.php
@@ -39,7 +39,7 @@ public function testEntityViewBuilderCache() {
     $cache_contexts_manager = \Drupal::service("cache_contexts_manager");
     $cache = \Drupal::cache();
 
-    // Force a request via GET so we can get drupal_render() cache working.
+    // Force a request via GET so we can get \Drupal::service(renderer)->render() cache working.
     $request = \Drupal::request();
     $request_method = $request->server->get('REQUEST_METHOD');
     $request->setMethod('GET');
@@ -92,7 +92,7 @@ public function testEntityViewBuilderCacheWithReferences() {
     $renderer = $this->container->get('renderer');
     $cache_contexts_manager = \Drupal::service("cache_contexts_manager");
 
-    // Force a request via GET so we can get drupal_render() cache working.
+    // Force a request via GET so we can get \Drupal::service(renderer)->render() cache working.
     $request = \Drupal::request();
     $request_method = $request->server->get('REQUEST_METHOD');
     $request->setMethod('GET');
diff --git a/core/tests/Drupal/Tests/Core/Render/RendererTest.php b/core/tests/Drupal/Tests/Core/Render/RendererTest.php
index bed7d3d..18beed5 100644
--- a/core/tests/Drupal/Tests/Core/Render/RendererTest.php
+++ b/core/tests/Drupal/Tests/Core/Render/RendererTest.php
@@ -367,7 +367,7 @@ public function testRenderSorting() {
     $this->assertTrue($elements['#sorted'], "'#sorted' => TRUE was added to the array");
 
     // Pass $elements through \Drupal\Core\Render\Element::children() and
-    // ensure it remains sorted in the correct order. drupal_render() will
+    // ensure it remains sorted in the correct order. \Drupal::service(renderer)->render() will
     // return an empty string if used on the same array in the same request.
     $children = Element::children($elements);
     $this->assertTrue(array_shift($children) == 'first', 'Child found in the correct order.');
