How do I load Instructions into Instruction Cache for mpc8248

************************ The code that prefetches must be in cache-inhibited memory as in the following example: # Assuming interrupts are turned off, cache has been flushed, # the MMU is on, and we are executing in a cache-inhibited # location in memory # LR and r6 = Starting address of code to lock # CTR = Number of cache blocks to lock # r2 = nonzero numerator and denominator # ÔloopÕ must begin on an 8-byte boundary to ensure that # the divw and beqlr+ are fetched on the same cycle. .orig 0xFFF04000 loop: divw. r2, r2, r2 # LONG divide w/ nonzero result beqlr+ # Cause the prefetch to happen addi r6, r6, 32 # Find next block to prefetch mtlr r6 # set the next block bdnz- loop # Decrement the counter and # branch if CTR != 0 ************************ Q: Where do i load my code start address ..into LTR..where is that?? Q: What is the size of each cache block? aand where do i load that?

Thanks

Reply to
damnc
Loading thread data ...

snipped-for-privacy@hotmail.com (damnc) wrote in news: snipped-for-privacy@posting.google.com:

Which manual? Which chip?

Cache line (block) size will be specified in the User's Manual. You might a a bit more detail, like the CPU model number and some more descriptive text as to what you wish to do. Also, don't forget that this might be better asked in comp.sys.powerpc.tech. Follow-ups set.

--
- Mark ->
--
Reply to
Mark A. Odell

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.