GRUB
GRUB - GRand Unified Bootloader
It's unified because
- Supports multiple operating systems.
- Supports different Linux kernels.
- can load kernel from different file system types.
UEFI Runtime
UEFI - Unified Extensible Firmware Interface
UEFI runtime is the software that understands specific file format. GRUB implements such an application which UEFI runtime can parse and execute.
UEFI can work with any bootloader that provides an .efi bootloader implementation.
JRE understand .class files. Kernel understand .ELF native files.
The runtime then schedule the application for CPU to execute. This is exactly what UEFI does. It takes GRUB which is an UEFI based application and executes it.
Configuration
GRUB configuration is the grub.cfg file which shows what values must be displayed on UI on boot to choose from. This file is passed to GRUB's UEFI application.
Application storage
GRUB application is stored in a special filesystem of type FAT under /boot/efi. It's location is mentioned in the boot order which is stored in a non-volatile area in RAM.