CPU和面向GPU的代码之间有什么区别? [英] What is the difference between a CPU and a GPU oriented code?

查看:143
本文介绍了CPU和面向GPU的代码之间有什么区别?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

让我们假设游戏开发人员开发应用程序.那么,在编写应用程序时,开发人员会写一些应该进入CPU的代码段,或者应该进入运行时的调度程序的代码段吗?

Let us suppose a game developer develops an application. So, while writing the application will the developer write some code segment which should goto CPU and some which should goto GPU or is decided by scheduler at run time?

推荐答案

CPU和GPU不同,经过优化可以执行不同的操作.与传统的CPU相比,GPU不太聪明,但是却具有更大的并行度并执行大量的专门处理.

CPUs and GPUs are different, optimised to do different things. GPUs are less clever, but massively more parallel and carry out a huge amount of specialised processing, as opposed to the traditional CPUs more general processing.

GPU必须由CPU分配任务.调度程序运行时的划分是不可能的,因为它们是不同的,能够执行不同的指令.

GPUs have to be tasked by the CPU. No scheduler run time devisions are possible, because they are different, capable of different instructions.

这篇关于CPU和面向GPU的代码之间有什么区别?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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