Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7678841
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T17:44:22+00:00 2026-05-31T17:44:22+00:00

Im doing a recursive fibonacci assignment in MIPS and simulated with qtSpim on my

  • 0

Im doing a recursive fibonacci assignment in MIPS and simulated with qtSpim on my mac and have it working. However, my teacher wants a way to check if the integer n is too large in the fib function and if so, “output the number is too large”. Any hints on how i could go about doing this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T17:44:24+00:00Added an answer on May 31, 2026 at 5:44 pm

    I don’t know much about the MIPS instruction set, but the general assembler approach is to check the carry flag after an operation. If it’s set, then the result was too big for (unsigned) arithmetic.

    AFAIK, MIPS doesn’t have a carry flag. But you can approximate one as follows:

    addu $t3, $t2, $t1  # t3 = t2 + t1
    sltu $t4, $t3, $t1  # t4 = 1 if carry occurred
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is there a way to exclude all svn externals when doing a recursive update?
I'm doing some recursive parsing. Currently I have a fake stack, where I store
What is the simplest way of doing a recursive self-join in SQL Server? PersonID
Okay so this is for a school assignment. I have had no problems doing
I am doing a recursive program and I am getting an error about conflicting
I was doing the exercises from YAHT's Recursive Datatype section, and found writing the
Doing some jquery animation. I have certain divs set up with an attribute of
Doing the Y-Combinator for a single argument function such as factorial or fibonacci in
I was in the middle of doing a recursive svn add/commit, and a folder
I'm doing some generic object comparison, using reflection and recursion. The recursive method needs

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.