Changeset 0287820 in mainline for kernel/arch/mips32/include/cycle.h


Ignore:
Timestamp:
2007-12-02T00:54:24Z (17 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
8df2eab
Parents:
d4e38c7
Message:

CPU cycle accounting on MIPS

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/mips32/include/cycle.h

    rd4e38c7 r0287820  
    3636#define KERN_mips32_CYCLE_H_
    3737
     38#include <arch/cp0.h>
     39#include <arch/interrupt.h>
     40
    3841static inline uint64_t get_cycle(void)
    3942{
    40         return 0;
     43        return ((uint64_t) count_hi << 32) + ((uint64_t) cp0_count_read());
    4144}
    4245
Note: See TracChangeset for help on using the changeset viewer.