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: yueng<penguin00@m...>
    Date: Thu Feb 14 09:44:56 CET 2008
    Subject: [openrisc] how use div in or1k
    Top

    in the C code

    a = b/c ; // all integers

    after compiler link
    it generate a l.jal 0 <_reset_100-0x100> , not a div instruction
    then jump to here
    Disassembly of section .vectors:
    23
    24 00000000 <_reset_100-0x100>:
    25 ...
    26
    27 00000100 <_reset_100>:
    28 100: 15 00 00 00 l.nop 0x0
    29 104: 00 00 08 1b l.j 2170 <_reset_except>
    30 108: 15 00 00 00 l.nop 0x0
    31 ...


    but a=b*c, will generate a l.mul r3,r3,r4

    how can i compile a correct div?

    thank you.




    --
    View this message in context: http://www.nabble.com/how-use-div-in-or1k-tp15476076p15476076.html
    Sent from the OpenCores - RISC mailing list archive at Nabble.com.

    Follow upAuthor
    [openrisc] how use div in or1kDimitri?s Orfanos

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