Re: [PATCH 0/4] Device id consolidation

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Quoting Tvrtko Ursulin (2019-03-28 09:23:24)
> 
> On 26/03/2019 07:40, Tvrtko Ursulin wrote:
> > From: Tvrtko Ursulin <tvrtko.ursulin@xxxxxxxxx>
> > 
> > Series removes device id checks from i915_drv.h macros and consolidates them to
> > i915_pciids.h as the main "database", while making intel_device_info.c reference
> > the former, expanding the existing concept of a platform mask by a few low bits
> > reserved for sub-platform mask.
> > 
> > This has a two-fold positive effect of firstly consolidating the list of device
> > ids to one location, and secondly removing the if-ladders from every
> > IS_<platfrom>_<subplatform> call site.
> > 
> > Maintenance burden is not completely removed but should be improved. One case in
> > point is that I have found some disagreements between device id listed in
> > i915_pciids.h and i915_drv.h.
> > 
> > At the same time platform mask code is generalized to an array of u32 to
> > accomodate the addition of EHL and avoid spilling into u64 which would cause a
> > small code size increase. Downside is that any platforms on the u32 boundary,
> > like currently ICL and EHL, lose the benefit of optimizing the "IS_ICELAKE ||
> > IS_ELKHARTLAKE" checks into a single conditional, although at the moment there
> > aren't any such call-sites.
> > 
> > Before vs after for the whole series:
> > 
> >     text    data     bss     dec     hex filename
> > 1891093   43903    7424 1942420  1da394 i915.ko.0
> > 1890434   43903    7424 1941761  1da101 i915.ko.1
> > 
> > add/remove: 12/3 grow/shrink: 92/121 up/down: 1974/-1769 (205)
> > ...
> > Total: Before=1286293, After=1286498, chg +0.02%
> 
> After patch 4 v8:
> 
>     text    data     bss     dec     hex filename
> 1904423   43891    7424 1955738  1dd79a i915.ko.0
> 1903354   43891    7424 1954669  1dd36d i915.ko.1
> 
> add/remove: 8/3 grow/shrink: 94/124 up/down: 1623/-1889 (-266)
> ...
> Total: Before=1293823, After=1293557, chg -0.02%

The series is an improvement, both for the reader and for the compiler,

Reviewed-by: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx>
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux