gcc中的选项,它允许我们为16位处理器生成目标代码 [英] option in gcc that lets us produce object code for 16-bit processor

查看:71
本文介绍了gcc中的选项,它允许我们为16位处理器生成目标代码的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我只是想知道gcc

编译器中是否有一个选项可以让我们为16位处理器生成目标代码,而

我们正在工作在32位计算机上。

解决方案

在文章< 11 ************** *******@s13g2000cwa.googlegroups。 com>,

chandanlinster< ch ************ @ gmail.comwrote:


>我只是想知道gcc
编译器中是否有一个选项可以让我们为16位处理器生成目标代码,而我们正在使用32位机器。



是,不,也许。


如果您需要gcc本身的帮助,您应该在其中一个中询问br />
gnu新闻组。


一般来说,gcc确实支持在完全不同的系统之间交叉编译甚至

,但它不是''一般来说,

移植了,所以没有你的进一步信息,我们就不会告诉你它是否支持-your-32位机器

或它是否支持-your-16位处理器。

-

编程就是当你''时发生的事情忙于制定其他计划。


chandanlinster(
11 ********************* @ s13g2000cwa.googlegroups.c om )说:


|我只是想知道gcc中是否有选项

|让我们为16位处理器生成目标代码的编译器,

|我们正在研发32位机器。


是的 - 看看目标处理器的gcc文档

选项。


-

Morris Dovey

DeSoto Solar

德索托,爱荷华州美国
http://www.iedu.com/DeSoto


< blockquote>

chandanlinster写道:


我只是想知道gcc中是否有选项

编译器让我们为16位处理器生成目标代码,而

我们正在使用32位机器。



假设你的意思是8086就像16位那么答案是否定的。据我所知,公共GCC档案并不是针对它的。


Cygnus确实提供基于GCC的编译器[或者他们至少用过] <各种8位和16位平台,其中很可能包括8086 [186

和286等]但是他们不是免费的。

一般来说回答这个问题......其他人已经回答了这个问题。为了总结

up,GCC通常被用作交叉编译器。这意味着你构建了一个不是你的HOST平台的
TARGET平台。 GCC有点怪异

它还有一个BUILD平台。也就是说,你可以在平台A上构建一个交叉的

编译器,在平台B上运行并为

平台C构建代码。[我的道歉,如果我的名字混合了这个。


汤姆


I was just curious to know whether there is an option within the gcc
compiler that lets us produce object code for 16-bit processor, while
we are working on 32-bit machines.

解决方案

In article <11*********************@s13g2000cwa.googlegroups. com>,
chandanlinster <ch************@gmail.comwrote:

>I was just curious to know whether there is an option within the gcc
compiler that lets us produce object code for 16-bit processor, while
we are working on 32-bit machines.

Yes, No, Maybe.

If you need assistance with gcc itself, you should ask in one of the
gnu newsgroups.

Generally speaking, gcc does support cross-compiling even
between completely different systems, but it isn''t been universally
ported yet, so without further information from you we wouldn''t
be able to tell you whether it is supported on -your- "32 bit machine"
or whether it supports -your- "16 bit processor".
--
Programming is what happens while you''re busy making other plans.


chandanlinster (in
11*********************@s13g2000cwa.googlegroups.c om) said:

| I was just curious to know whether there is an option within the gcc
| compiler that lets us produce object code for 16-bit processor,
| while we are working on 32-bit machines.

Yes - take a look at the gcc documentation for target processor
options.

--
Morris Dovey
DeSoto Solar
DeSoto, Iowa USA
http://www.iedu.com/DeSoto



chandanlinster wrote:

I was just curious to know whether there is an option within the gcc
compiler that lets us produce object code for 16-bit processor, while
we are working on 32-bit machines.

Assuming you mean 8086 like 16-bit then the answer is no. As far as I
know the public GCC archives do not target it.

Cygnus does offer GCC based compilers [or they used to at least] for
various 8 and 16-bit platforms which most likely included the 8086 [186
and 286, etc] but they''re not free.

To answer the question in general ... others have answered it. To sum
up, GCC is often used as a "cross-compiler" which means you build for a
TARGET platform which is not your HOST platform. GCC is a bit weirder
that it also has a BUILD platform. That is, you can build a cross
compiler on platform A, to run on platform B and build code for
platform C. [my apologies if I got the names mixed up].

Tom


这篇关于gcc中的选项,它允许我们为16位处理器生成目标代码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆