# vim: filetype=yaml
#
# All core and cache configuration will be in a separate file and that will be
# included in the final config file using 'import: [filename, ...]'

# Import files that define various core/caches
import:
  - ooo_core.conf
  - atom_core.conf
  - l1_cache.conf
  - l2_cache.conf
  - moesi.conf

memory:
  dram_cont:
    base: simple_dram_cont

machine:
  shared_l2_4core_4M:
    description: Shared L2 Configuration
    min_contexts: 4
    max_contexts: 4 
    cores: # The order in which core is defined is used to assign
           # the cores in a machine
      - type: ooo
        name_prefix: ooo_
        option:
            threads: 1
    caches:
      - type: l1_64K_mesi
        name_prefix: L1_I_
        insts: $NUMCORES # Per core L1-I cache
        option:
            private: true
            last_private: true
      - type: l1_64K_mesi
        name_prefix: L1_D_
        insts: $NUMCORES # Per core L1-D cache
        option:
            private: true
            last_private: true
      - type: l2_4M #previous l2_8M
        name_prefix: L2_
        insts: 1 # Shared L2 config
    memory:
      - type: dram_cont
        name_prefix: MEM_
        insts: 1 # Single DRAM controller
        option:
            latency: 50
    interconnects:
      - type: p2p
        # '$' sign is used to map matching instances like:
        # cpu_0, L1_I_0
        connections:
            - core_$: I
              L1_I_$: UPPER
            - core_$: D
              L1_D_$: UPPER
            - L2_0: LOWER
              MEM_0: UPPER
      - type: split_bus
        connections:
            - L1_I_*: LOWER
              L1_D_*: LOWER
              L2_0: UPPER

  shared_l2_4core_8M:
    description: Shared L2 Configuration
    min_contexts: 4
    max_contexts: 4 
    cores: # The order in which core is defined is used to assign
           # the cores in a machine
      - type: ooo
        name_prefix: ooo_
        option:
            threads: 1
    caches:
      - type: l1_64K_mesi
        name_prefix: L1_I_
        insts: $NUMCORES # Per core L1-I cache
        option:
            private: true
            last_private: true
      - type: l1_64K_mesi
        name_prefix: L1_D_
        insts: $NUMCORES # Per core L1-D cache
        option:
            private: true
            last_private: true
      - type: l2_8M # 4M cpsd to 8M
        name_prefix: L2_
        insts: 1 # Shared L2 config
    memory:
      - type: dram_cont
        name_prefix: MEM_
        insts: 1 # Single DRAM controller
        option:
            latency: 50
    interconnects:
      - type: p2p
        # '$' sign is used to map matching instances like:
        # cpu_0, L1_I_0
        connections:
            - core_$: I
              L1_I_$: UPPER
            - core_$: D
              L1_D_$: UPPER
            - L2_0: LOWER
              MEM_0: UPPER
      - type: split_bus
        connections:
            - L1_I_*: LOWER
              L1_D_*: LOWER
              L2_0: UPPER

