LOGIN   :::   RECOVER PASS   :::   GET ACCOUNT    
Browse
  • Projects
  • Code (CVS)
  • Forums
  • News
  • Articles
  • Polls
  •  
    OpenCores
  • FAQ
  • CVS HowTo
  • Mission
  • Media
  • Tools
  • Advertise
  • Mirrors
  • Logos
  • Contact us
  • Find Resources
  • Job Opportunity
  •  
    Tools
  • Search
      
  • Download Cores (CVSGet)
  •  
    More
  • Wishbone
  • Perlilog
  • EDA tools
  • OpenTech CD
  •  
    Navigation: All forums > Openrisc > Message List > Message Post

    Message

    Reply | Reply all
    Date Prev | Date Next | Thread Prev | Thread Next Date Index | Thread Index

    From: =?unknown-8bit?Q?Gy=F6rgy?= 'nog' Jeney<nog@s...>
    Date: Thu Jun 30 11:20:12 CEST 2005
    Subject: [openrisc] [or1ksim #107] Remove useless calls to m{f,t}spr
    Top
    > * Gy?rgy 'nog' Jeney (nog@s...) wrote:
    > > Hi,
    > >
    > > There has been a nice amount of traffic on openrisc in the last days, may aswell
    > > add my own :)
    > >
    > > ChangeLog:
    > > * Remove m{f,t}spr calls where we can access the spr directly.
    >
    > i would think that it is better (for readability) to have
    > m{f,t}spr_internal function, that is an inline of what you suggest. it's
    > just as fast and you still keep the m{f,t}spr abstraction...

    mfspr_internal(spr)
    cpu_state.sprs[spr]

    What's the difference for readability? The one has round brackets, the other
    square ones and they're even the same length. What abstraction are you thinking
    of? The whole idea is that there should not be any abstraction. As soon as we
    have abstraction, doing stuff like mtspr_internal(SPR_NPC, ) is expected to do
    the right thing (alter the course of execution), which is impossible to do
    without conditions, in which case we're no better of than what's there
    currently.

    nog.

    ReferenceAuthor
    [openrisc] [or1ksim #107] Remove useless calls to m{f,t}sprMatjaz Breskvar

    Follow upAuthor
    [openrisc] [or1ksim #107] Remove useless calls to m{f,t}sprMatjaz Breskvar

     
    Copyright (c) 1999 OPENCORES.ORG. All rights reserved.