Sometimes ago, Matt Cutts stated that Google took out webpages that returned a 410 faster than with 404. Since this 2014 video, we didn’t find any official google communication that contradicted this statement.
In HTACCESS, here is are the directives to redirect all pages to 410 except the robots.txt and the sitemap.xml:
RewriteEngine On
RewriteCond %{REQUEST_URI} !^/robots\.txt$
RewriteCond %{REQUEST_URI} !^/sitemap\.xml$
RewriteRule ^(.*)$ - [G]
I haven’t added the robots.txt and sitemap.xml to 410 because with a robots.txt & sitemap.xml in place it speeds up the process to de-index the web pages from Google Index. It is the fastest way to de-index URLs from the Google Index.