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

  • Home
  • SEARCH
  • 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 1055639
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T17:35:40+00:00 2026-05-16T17:35:40+00:00

I am trying to print a string in a way that’s OS-neutral. For example,

  • 0

I am trying to print a string in a way that’s OS-neutral. For example, the program should run the same on Windows as it does on *nix.

Is this even possible? I’m assuming that since the underlying architecture is the same (x86) that the method would be the same. Is it as simple as calling an interrupt?

The reason for this is I’m trying to write a compiler that generates assembly code – at this early point in its development, only a handful of features are present – I’d like to be able to test the generated assembly code in either Windows or *nix. Down the road, it will be impossible to maintain platform-neutrality while generating the same code, but basically all I want to do at this point is print a string.

  • 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-16T17:35:41+00:00Added an answer on May 16, 2026 at 5:35 pm

    Pure assembly should not be considered portable between operating systems. There is no universal way to interact with system services from assembly. You shouldn’t even assume portability between Unix-like OSes (POSIX doesn’t specify a calling convention, though some x86 Unices do use a common convention).

    Even in higher-level languages, calling conventions can technically vary from one compiler to the next on the exact same CPU+OS, though usually compilers use whatever convention is specified for the host environment.

    See also Wikipedia’s page on x86 calling conventions.

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

Sidebar

Related Questions

I'm trying to write a command in LaTeX that takes a string such as
I'm trying to set up a program to record a portion of an internet
Trying to instantiate a class based on a string value and... failing. The parser
I am trying to use Spring Security 3.0.5 in my web application. Basically, I
I'm trying to create a function to read Morse code from one file, convert
For an exercise I'm doing, I'm trying to read the contents of a given
I'm trying to save myself just a few keystrokes for a command I type
I'm trying to pass an array of character arrays to a C function using
I got my test XML file to print using the following source file, but
I'm currently running into a bit of a problem. I'm trying to write a

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.