• Akash Goel's avatar
    drm/i915: Use SSE4.1 movntdqa based memcpy for sampling GuC log buffer · 71706590
    Akash Goel authored
    To ensure that we always get the up-to-date data from log buffer, its
    better to access the buffer through an uncached CPU mapping. Also the way
    buffer is accessed from GuC & Host side, manually doing cache flush may
    not be effective always if cached CPU mapping is used. In order to avoid
    any performance drop & have fast reads from the GuC log buffer, used SSE4.1
    movntdqa based memcpy function i915_memcpy_from_wc, as copying using
    movntqda from WC type memory is almost as fast as reading from WB memory.
    This way log buffer sampling time will not get increased and so would be
    able to deal with the flush interrupt storm when GuC is generating logs at
    a very high rate.
    Ideally SSE 4.1 should be present on all chipsets supporting GuC based
    submisssions, but if not then logging will not be enabled.
    
    v2: Rebase.
    
    v3: Squash the WC type vmalloc mapping patch with this patch. (Chris)
    Suggested-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
    Signed-off-by: default avatarAkash Goel <akash.goel@intel.com>
    Reviewed-by: default avatarTvrtko Ursulin <tvrtko.ursulin@intel.com>
    Signed-off-by: default avatarTvrtko Ursulin <tvrtko.ursulin@intel.com>
    71706590
i915_guc_submission.c 48 KB