线程可以成为进程吗? [英] can a thread be a process?

查看:205
本文介绍了线程可以成为进程吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

因为进程在其自己的系统资源和内存集中运行.那么,线程如何成为进程?

但是,线程共享该进程的资源和内存.

Because a process runs in its own set of system resources and memory. So, how can a thread be a process?

However a thread shares the resources and memory of the process.

推荐答案

总荒谬.根据定义,线程和进程是完全不同的概念.进程不是一种线程;它不是线程.线程不是一种过程;一个进程总是拥有"一个或多个线程.也有应用领域,有纤维.装配体.模块.就这样.

没什么可讨论的.我什至没有理由推荐任何读物.
Total absurd. Thread and process are completely different notions by definition. Process is not a kind of thread; thread is not a kind of process; a process always "owns" one or more threads. There are also application domains, there are fibers. Assemblies. Modules. That''s it.

Nothing to discuss. I don''t even see a reason to recommend any reading.


您从哪里得知线程可以是一个进程"?从某种意义上讲,它不是但根据定义,如果一个进程是否由单个线程组成,则可以将一个线程称为一个进程(尽管这并不意味着它是!).

线程是操作系统向其分配处理器时间的基本单位.用最简单的术语来说,一个过程是一个正在执行的程序.一个或多个线程在该进程的上下文中运行.

此处阅读 [阅读 [
Where from you came to know that ''thread can be a process''? In a sense it does not but by definition if a process consists of single thread then one can call a thread as a process (though it does not mean it is!).

A thread is the basic unit to which the operating system allocates processor time. A process, in the simplest terms, is an executing program. One or more threads run in the context of the process.

Read here[^] for more details.

Another read[^], a good one.


SAKryukow是正确的,请参阅此处以了解更多信息:
http://msdn.microsoft.com/en-us/library/ms684841% 28VS.85%29.aspx [ ^ ]
SAKryukow is right, see here for more information:
http://msdn.microsoft.com/en-us/library/ms684841%28VS.85%29.aspx[^]


这篇关于线程可以成为进程吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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