gem5-dev@gem5.org

The gem5 Developer List

View all threads

What is the meaning of flatten in reg_class

YZ
Yibo Zhang
Tue, Jun 25, 2024 12:16 AM

Hi everyone, I was trying to modify the Rename module of the O3 CPU and I found that the Rename for the destination register calls 'dest_reg.flatten(*isa)', I want to know what is the meaning of flatten for the register, I found the definition and the implementation in reg_class.hh but when I read the source code I couldn't understand the meaning of flatten. I found the definition and implementation in reg_class.hh, but when I read the source code, I can't understand the meaning of flatten, can someone please tell me what is the meaning of register flatten in reg_class or gem5?

Thanks!

Yibo Zhang

Best wishes!

Hi everyone, I was trying to modify the Rename module of the O3 CPU and I found that the Rename for the destination register calls 'dest_reg.flatten(*isa)', I want to know what is the meaning of flatten for the register, I found the definition and the implementation in reg_class.hh but when I read the source code I couldn't understand the meaning of flatten. I found the definition and implementation in reg_class.hh, but when I read the source code, I can't understand the meaning of flatten, can someone please tell me what is the meaning of register flatten in reg_class or gem5? Thanks! Yibo Zhang Best wishes!