[Beignet] [PATCH v2] remove lspci, gbe_bin_genenrater would generator llvm binary by default.

Zhigang Gong zhigang.gong at linux.intel.com
Tue Jul 8 17:32:30 PDT 2014


On Wed, Jul 09, 2014 at 12:29:44AM +0800, Yichao Yu wrote:
> On Tue, Jul 8, 2014 at 10:56 PM, Andi Kleen <andi at firstfloor.org> wrote:
> > xionghu.luo at intel.com writes:
> >
> >> From: Luo <xionghu.luo at intel.com>
> >>
> >> driver can get chipset id by ioctl instead of calling lspci in cmake;
> >> user could generator gen binary by configuring cmake option
> >> -DGEN_PCI_ID=xxxx or calling the gbe_bin_generater with option -t
> >> GEN_PCI_ID.
> >
> > But what would a distribution do which wants to run on all supported
> > hardware? Build beignet multiple times with different options?
> >
> > I think you need an option to generate binaries for all supported
> > targets.
> 
> I think the point of generating llvm binary (by default) is making it
> architecture independent. Therefore, the distribution should just
Eaxctly, the llvm binary is target independent.

> build the package WITHOUT setting GEN_PCI_ID. There's no need to add
> an option to generate all hardware-specific binaries (unless using
> llvm binaries have significant overhead.)
The GEN_PCI_ID is only for the cross compilation and reduce memory
footprint usage. Which is:
The target platform will not include a full compiler backend which is to
reduce memory footprint. Without full compiler backend, beignet could reduce
memory footprint from 12MB to 2 MB. In the mean time, it could not compile
any code from source type or from llvm type. It can only execute a binary
code, so you need to build all custom kernels offline by using gbe_bin_generater.

The llvm binaries don't have too much overhead. Those internal kernels
are simple to compile from LLVM to Gen code. And that compilation will
only occur once in the same application.

> 
> >
> > -Andi
> >
> > _______________________________________________
> > Beignet mailing list
> > Beignet at lists.freedesktop.org
> > http://lists.freedesktop.org/mailman/listinfo/beignet
> _______________________________________________
> Beignet mailing list
> Beignet at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/beignet


More information about the Beignet mailing list