Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

MIPS Assembly

Posted on 2013-01-14
8
Medium Priority
?
565 Views
Last Modified: 2013-02-17
How Can I print 2 more string on this code:

la $a0, hello_msg
        li $v0, 4
        syscall


Why I cannot do it like this: !!! Loading the address into 3 differant addresses and then Calling the print_string()??? Please explain clearly....

la $a0, hello_msg1
la $a1, hello_msg2
la $a2, hello_msg3

        li $v0, 4
        syscall
0
Comment
Question by:pauledwardian
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
8 Comments
 
LVL 25

Assisted Solution

by:Kyle Hamilton
Kyle Hamilton earned 2000 total points
ID: 38786926
im not an expert by any means, but assembly doesnt have highlevel functions like print_string(). are you writing this in C and compiling to assembly?

i probably cant help you, but i hope you dont mind if i tag along on this question.
0
 
LVL 82

Expert Comment

by:leakim971
ID: 38787132
Because print_string accept only one argument in $a0 and not in $a1, $a2

http://www.tfinley.net/notes/cps104/mips.html
0
 
LVL 25

Assisted Solution

by:Kyle Hamilton
Kyle Hamilton earned 2000 total points
ID: 38787856
haha, I thought you were referring to an an actual MIPS microprocessor. But you're talking about a language called MIPS, which by the way, is not assembly, but more like C.

:)
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
LVL 82

Expert Comment

by:leakim971
ID: 38787875
@kozaiwaniec

Did you never call an OS function with assembly? ;-)
0
 
LVL 25

Accepted Solution

by:
Kyle Hamilton earned 2000 total points
ID: 38788113
no... that's why I was confused, and wanted to see the outcome of this question.

I did a little assembly using just a small instruction set on the PIC16 microcontroller to make an LED matrix display some messages, but that's the extent of my experience - doh! :)

Thanks.
0
 

Author Closing Comment

by:pauledwardian
ID: 38900357
thanks!
0

Featured Post

Enroll in October's Free Course of the Month

Do you work with and analyze data? Enroll in October's Course of the Month for 7+ hours of SQL training, allowing you to quickly and efficiently store or retrieve data. It's free for Premium Members, Team Accounts, and Qualified Experts!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This is about my first experience with programming Arduino.
In this post we will learn how to make Android Gesture Tutorial and give different functionality whenever a user Touch or Scroll android screen.
The viewer will be introduced to the member functions push_back and pop_back of the vector class. The video will teach the difference between the two as well as how to use each one along with its functionality.
Introduction to Processes
Suggested Courses

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question