This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Instruction Count and Memory Access

Hello, 

I was looking into the debug and trace features in the Arm Musca Board A1, which implements the Corelink SSE 200 IP (dual core Cortex M33, each with a three-stage pipeline), I came across the data watchpoint and trace and his ability to estimate how many instructions have been executed.

My doubt is:

  • Can I relate the number of instructions executed with memory access. From what I read, but I am not sure, the core fetches 32 bit of data and most instructions are 16 bits. My line of thought was: use one of the DWT counters (DWT_CPICNT) that tells me, +-, how many stalls have been, plus the number of instructions that have been executed. If I know how many instructions are fetched per memory access I get in some "weird" way the number of memory accesses ?!?!

Correct me if my line of thought is wrong cause I am not 100% sure if this is correct.

Cheers!

Parents Reply Children
  • Hey !! 

    Thank you! I am already using them. I was wondering if it is possible to relate executed instructions with memory accesses.
    For example: If the core executed +- 1000 instructions in one second and it fetches 32 bits each time, and in Thumb code instructions can be 16 or 32 bits.
    So let's say that each fetch is 1.5 instructions, so 1000 * 32 bits / 1.5 ~= 21332 Bits = 2666 bytes read in one second ?!?! I know this is probably really dumb but I was just wondering x) (Pls note that there are a lot of assumptions here)

    Cheers!