开发者

PA-RISC inline assembly with HP CC compiler [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center. Closed 11 years ago.

I need to port some code written with a GCC compiler and inline assembly to its HP Unix equivalent. The situation is that HP CC compiler does not support the _asm keyword and of course the syntax is completely different. I have been looking on the internet for days but I have not found much information. The most I got is some information about the header file inline.h which has all the defini开发者_Go百科tions of some macros that, as I understand, are equivalent to some kind of assembly functions.

I have not found any example that can guide me. All the HP documentation I have found is about Itanium assembly language, which is a completely different architecture from PA-RISC.

Can someone please point me to some online resources about PA-RISC inline assembly with the HP CC compiler? Or at least some examples.


Your computer speaks Spanish (RISC Assembly).
Somebody wrote instructions in Chinese for a Chinese speaking computer.
You need to translate from Chinese to Spanish.
Not knowing both languages makes it an impossible job, examples notwithstanding.

Suggestion: ask the original programmer to rewrite the code in plain C.


As an alternative to rewriting the assembly in a different assembler format, you could use gcc on your hpux.

Of course, if the assembly was written for a different processor, then you'll have to follow @pmg's advice and ask for a generic C version. (Which is one of the reasons why C became so popular! It worked on multiple architectures once a compiler code generator was written for the target platform! Woot.)

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜