From: Jani Nikula <jani.nikula@intel.com>
To: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>,
Chris Wilson <chris@chris-wilson.co.uk>,
Intel-gfx@lists.freedesktop.org
Subject: Re: [RFC 4/7] drm/i915: Remove mkwrite_device_info
Date: Tue, 13 Nov 2018 13:28:11 +0200 [thread overview]
Message-ID: <87k1lhgqt0.fsf@intel.com> (raw)
In-Reply-To: <3f00e395-c753-4164-7b11-471370dc7038@linux.intel.com>
On Tue, 13 Nov 2018, Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> wrote:
> On 12/11/2018 17:25, Chris Wilson wrote:
>> Quoting Tvrtko Ursulin (2018-11-12 17:12:39)
>>> From: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
>>>
>>> Now that we are down to one caller, which does not even modify copied
>>> device info, we can remove the mkwrite_device_info helper and convert the
>>> device info pointer itself to be a pointer to static table instead of a
>>> copy.
>>
>> The copy was deliberate to avoid the extra pointer. How does the change
>> in code size now compare?
>
> AFAIR grows a bit, but overall series still ends up overall smaller. I
> need to re-run the numbers for more concrete info.
>
> However, if we keep having a copy, ie. do not make device info properly
> read-only, are we still interested in splitting the two? Benefit would
> be diminished, but presumably people still think it would be worth it?
If we don't turn device info into a pointer to the static const structs,
IMO there's simply no point in any of this. Then we might just as well
drop the const and mkwrite_device_info, and use the mutable thing all
over the place.
Modifying the device info copy was supposed to be an exception at the
time of the copy, but with mkwrite_device_info it has proliferated. It's
silly and ugly and wrong with no benefits. The const was put in place to
hint that it's not supposed to be modified, but that didn't work out.
So which is it, runtime/static split with an extra pointer chase to the
const data in rodata (I'm in favor), or just drop the const from the
dev_priv copy and remove mkwrite_device_info?
The latter makes future attempts at utilizing DCE/LTO with a reduced
number of device infos much harder I think.
BR,
Jani.
--
Jani Nikula, Intel Open Source Graphics Center
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2018-11-13 11:28 UTC|newest]
Thread overview: 39+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-12 17:12 [RFC 0/7] mkwrite_device_info removal Tvrtko Ursulin
2018-11-12 17:12 ` [RFC 1/7] drm/i915: Remove has_pooled_eu static initializer Tvrtko Ursulin
2018-11-12 17:29 ` Ville Syrjälä
2018-11-12 17:12 ` [RFC 2/7] drm/i915: Introduce runtime device info Tvrtko Ursulin
2018-11-12 17:36 ` Ville Syrjälä
2018-11-13 9:11 ` Tvrtko Ursulin
2018-11-12 17:12 ` [RFC 3/7] drm/i915: Move all runtime modified device info fields into runtime info Tvrtko Ursulin
2018-11-12 17:24 ` Chris Wilson
2018-11-13 9:13 ` Tvrtko Ursulin
2018-11-13 9:42 ` Chris Wilson
2018-11-12 21:22 ` Lucas De Marchi
2018-11-13 9:19 ` Tvrtko Ursulin
2018-11-12 17:12 ` [RFC 4/7] drm/i915: Remove mkwrite_device_info Tvrtko Ursulin
2018-11-12 17:25 ` Chris Wilson
2018-11-13 9:16 ` Tvrtko Ursulin
2018-11-13 11:28 ` Jani Nikula [this message]
2018-11-13 11:34 ` Chris Wilson
2018-11-13 11:45 ` Jani Nikula
2018-11-13 11:50 ` Jani Nikula
2018-11-13 11:51 ` Chris Wilson
2018-11-13 17:33 ` Tvrtko Ursulin
2018-11-13 17:40 ` Chris Wilson
2018-11-13 17:15 ` Tvrtko Ursulin
2018-11-12 17:12 ` [RFC 5/7] drm/i915: Move gen and platform mask to runtime device info Tvrtko Ursulin
2018-11-13 11:30 ` Jani Nikula
2018-11-13 11:48 ` Tvrtko Ursulin
2018-11-13 11:58 ` Tvrtko Ursulin
2018-11-12 17:12 ` [RFC 6/7] drm/i915: Introduce subplatform concept Tvrtko Ursulin
2018-11-12 17:29 ` Chris Wilson
2018-11-13 9:17 ` Tvrtko Ursulin
2018-11-13 11:40 ` Jani Nikula
2018-11-13 17:11 ` Tvrtko Ursulin
2018-11-13 22:28 ` Jani Nikula
2018-11-15 11:03 ` Tvrtko Ursulin
2019-03-25 18:00 ` Tvrtko Ursulin
2018-11-12 17:12 ` [RFC 7/7] drm/i915: Remove double underscore from static device info member names Tvrtko Ursulin
2018-11-12 17:34 ` ✗ Fi.CI.CHECKPATCH: warning for mkwrite_device_info removal Patchwork
2018-11-12 17:37 ` ✗ Fi.CI.SPARSE: " Patchwork
2018-11-12 17:50 ` ✗ Fi.CI.BAT: failure " Patchwork
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87k1lhgqt0.fsf@intel.com \
--to=jani.nikula@intel.com \
--cc=Intel-gfx@lists.freedesktop.org \
--cc=chris@chris-wilson.co.uk \
--cc=tvrtko.ursulin@linux.intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).