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 6687171
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T05:15:25+00:00 2026-05-26T05:15:25+00:00

I read that .asciiz null terminates the string (appending \n ?) … but when

  • 0

I read that .asciiz null terminates the string (appending \n?) … but when looking at the User Data Segment of QtSPIM,

User data segment [10000000]..[10040000]
[10000000]..[1000ffff]  00000000
[10010000]    6c6c6548  6f57206f  00646c72  6c6c6548    H e l l o   W o r l d . H e l l 
[10010010]    6f57206f  00646c72  00000000  00000000    o   W o r l d . . . . . . . . . 
[10010020]..[1003ffff]  00000000

I don’t see a difference?

.data
  str1: .asciiz "Hello World" # string str1 = "Hello World"
  str2: .ascii "Hello World" # string str2 = "Hello World"

.text
  .globl main
    main: 
      li $v0, 4 # print_string

      # print(str1)
      la $a0, str1 # load address of str1 into $a0
      syscall

      # print(str2)
      la $a0, str2 # load address of str2 into $a0
      syscall

      j $ra

Outputs “Hello WorldHello World“

UPDATE

What are the implications or when do I use each? asciiz sounds like the “proper” method?

  • 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-26T05:15:26+00:00Added an answer on May 26, 2026 at 5:15 am

    As written by @osgx, ASCIIZ means that the string is terminated by the \0 (ASCII code 0) NUL character. They are even called C strings. To quote from there:

    In computing, a C string is a character sequence terminated with a
    null character (‘\0’, called NUL in ASCII). It is usually stored as
    one-dimensional character array.[dubious – discuss] The name refers to
    the C programming language which uses this string representation.
    Alternative names are ASCIIZ (note that C strings do not imply the use
    of ASCII) and null-terminated string.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I read that you should define your JavaScript functions in the <head> tag, but
i am getting response from server in utf-8 but not able to read that.
I have to read invoice ascii files that are structured in a really convoluted
I read that you could call JavaScript code from a Java Applet by calling
I read that Domain Driven Design is about concentrating on the problem domain instead
I read that SQL exceptions are treated as normal exceptions in managed SPs; I
I read that defined styles are located at C:\Program Files\Microsoft Office\Office12\Bibliography\Style I use ISO
I read that some webmail services prefetch url links in emails. The GET request
I read that .NET uses connection pooling. For example, if I instantiate a bunch
I read that when you don't have access to the web server's headers you

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.