OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [tags/] [nog_patch_67/] [or1ksim/] [bpb/] [branch_predict.c] - Diff between revs 541 and 997

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 541 Rev 997
Line 61... Line 61...
} bpb[BPB_LEN];
} bpb[BPB_LEN];
 
 
void bpb_info()
void bpb_info()
{
{
        if (!config.bpb.enabled) {
        if (!config.bpb.enabled) {
                printf("BPB not simulated. Check -bpb option.\n");
                PRINTF("BPB not simulated. Check -bpb option.\n");
                return;
                return;
        }
        }
 
 
        printf("BPB %d bytes: ", BPB_LEN * BPB_WAYS * (BPB_PSTATES + BPB_USTATES) / 8);
        PRINTF("BPB %d bytes: ", BPB_LEN * BPB_WAYS * (BPB_PSTATES + BPB_USTATES) / 8);
        printf("%d ways, %d sets, %d bits/prediction\n", BPB_WAYS, BPB_LEN, BPB_PSTATES + BPB_USTATES);
        PRINTF("%d ways, %d sets, %d bits/prediction\n", BPB_WAYS, BPB_LEN, BPB_PSTATES + BPB_USTATES);
}
}
 
 
/* First check if branch is already in the cache and if it is:
/* First check if branch is already in the cache and if it is:
    - increment BPB hit stats,
    - increment BPB hit stats,
    - set 'lru' at this way to BPB_USTATES - 1 and
    - set 'lru' at this way to BPB_USTATES - 1 and
Line 165... Line 165...
} btic[BTIC_LEN];
} btic[BTIC_LEN];
 
 
void btic_info()
void btic_info()
{
{
        if (!config.bpb.btic) {
        if (!config.bpb.btic) {
                printf("BTIC not simulated. Check --btic option.\n");
                PRINTF("BTIC not simulated. Check --btic option.\n");
                return;
                return;
        }
        }
 
 
        printf("BTIC %d bytes: ", BTIC_LEN * BTIC_WAYS * (BTIC_USTATES + BTIC_BLOCKSIZE * 8) / 8);
        PRINTF("BTIC %d bytes: ", BTIC_LEN * BTIC_WAYS * (BTIC_USTATES + BTIC_BLOCKSIZE * 8) / 8);
        printf("%d ways, %d sets, %d bits/target\n", BTIC_WAYS, BTIC_LEN, BTIC_USTATES + BTIC_BLOCKSIZE * 8);
        PRINTF("%d ways, %d sets, %d bits/target\n", BTIC_WAYS, BTIC_LEN, BTIC_USTATES + BTIC_BLOCKSIZE * 8);
}
}
 
 
/* First check if target addr is already in the cache and if it is:
/* First check if target addr is already in the cache and if it is:
    - increment BTIC hit stats,
    - increment BTIC hit stats,
    - set 'lru' at this way to BTIC_USTATES - 1 and
    - set 'lru' at this way to BTIC_USTATES - 1 and

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.