Question

Can someone, please, explain in plain and simple words what exactly is the Register file?
I have a basic understanding of how the CPU works, and little experience with assembly code, but I just couldn't find anywhere a (good) explanation for it.
Is it what we mean when we say "CPU registers"? Is it a cache memory (meaning some hardware component that seats closest [or onto] the CPU)? if so - why is it called "register file"? aren't files just an abstractions? does it have anything to do with the addressable words we use in assembly coding? (%eax, %ebx, %ecx etc...)
I tried to google it and read Wikipedia for "register file", but couldn't find answers for it.

Was it helpful?

Solution

Register is a fast memory storage. The register names in assembly languages are just instruction set exposed registers, which may or may not map directly to the hardware register. Modern CPUs often use register renaming to rearrange instructions, make them execute at the same time, so the number of registers that are used to store values may be much larger. Register file is a group of them.

In hardware, register is in fact any of the data storage means constructed from flip-flops. Between pipelines there must be registers, between the blocks there may also be many flip-flops in input/output ports, and each blocks also have lots of register to calculate and store intermedia values just like variables in software

OTHER TIPS

Register are indeed some hardware component inside the CPU. In term of speed, there are even closer than the memory caches which hold local copies of small portions of the memory. The term file only means the gathering of all the registers together with the hardware connection used to access them. It has nothing to do with disks or filesystems.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top