Base64 encoding and decoding at almost the speed of a memory copy. (26th November 2019)
- Record Type:
- Journal Article
- Title:
- Base64 encoding and decoding at almost the speed of a memory copy. (26th November 2019)
- Main Title:
- Base64 encoding and decoding at almost the speed of a memory copy
- Authors:
- Muła, Wojciech
Lemire, Daniel - Abstract:
- Summary: Many common document formats on the Internet are text‐only such as email (MIME) and the Web (HTML, JavaScript, JSON, and XML). To include images or executable code in these documents, we first encode them as text using base64. Standard base64 encoding uses 64 ASCII characters, ie, both lower and upper case Latin letters, digits and two other symbols. We show how we can encode and decode base64 data at nearly the speed of a memory copy (memcpy ) on recent Intel processors, as long as the data does not fit in the first‐level (L1) cache. We use the single‐instruction‐multiple‐data instruction set AVX‐512 available on commodity processors. Our implementation generates several times fewer instructions than previous single‐instruction‐multiple‐data‐accelerated base64 codecs. It is also more versatile, as it can be adapted, even at runtime, to any base64 variant by only changing constants.
- Is Part Of:
- Software, practice & experience. Volume 50:Number 2(2020)
- Journal:
- Software, practice & experience
- Issue:
- Volume 50:Number 2(2020)
- Issue Display:
- Volume 50, Issue 2 (2020)
- Year:
- 2020
- Volume:
- 50
- Issue:
- 2
- Issue Sort Value:
- 2020-0050-0002-0000
- Page Start:
- 89
- Page End:
- 97
- Publication Date:
- 2019-11-26
- Subjects:
- binary‐to‐text encoding -- data URI -- vectorization -- web performance
Computer software -- Periodicals
Computer programming -- Periodicals
Computer programs -- Periodicals
005.3 - Journal URLs:
- http://onlinelibrary.wiley.com/ ↗
- DOI:
- 10.1002/spe.2777 ↗
- Languages:
- English
- ISSNs:
- 0038-0644
- Deposit Type:
- Legaldeposit
- View Content:
- Available online (eLD content is only available in our Reading Rooms) ↗
- Physical Locations:
- British Library DSC - 8321.453000
British Library DSC - BLDSS-3PM
British Library STI - ELD Digital store - Ingest File:
- 12549.xml