| Message ID | 20260706222245.247396-1-bryan.odonoghue@linaro.org |
|---|---|
| Headers | show
Return-Path: <libcamera-devel-bounces@lists.libcamera.org> X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id 6D1CBC3308 for <parsemail@patchwork.libcamera.org>; Mon, 6 Jul 2026 22:22:59 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 1B32E6605A; Tue, 7 Jul 2026 00:22:58 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="Kn0nAaq7"; dkim-atps=neutral Received: from mail-wr1-x42c.google.com (mail-wr1-x42c.google.com [IPv6:2a00:1450:4864:20::42c]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 7B85965FBE for <libcamera-devel@lists.libcamera.org>; Tue, 7 Jul 2026 00:22:56 +0200 (CEST) Received: by mail-wr1-x42c.google.com with SMTP id ffacd0b85a97d-47640541585so2175480f8f.1 for <libcamera-devel@lists.libcamera.org>; Mon, 06 Jul 2026 15:22:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1783376576; x=1783981376; darn=lists.libcamera.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=eR/J/KjMv3FFWydwvAFVCsF7iB7TZfoT6HA7WxELzng=; b=Kn0nAaq7cIvbc4bUUFGrmHKOP7MAhIN2g0c4nU2xs40ShmJTgsC+rwMaD3BSkYQpM5 0jZrtdrpOjKCiLNGNHkHX1Xm0aedaWpKSumOCfstUWlrEpp73vb+yPtq1ur97+HsEGhS 56Fgxa4U6hFCvlEYh4Bbr6xE9WOg4hbbXpn6jAfoA9jiypB2xJXy/gFCQVH4MExlDmH1 UjfAF7wpPnevx1iYA/5a+mQZwIoVzgs7AuDE8K8dUG2O36zFpSHhyIQ6iva41qJcX0cx V9KdeL91A8l9H2VB4pkzvyO5/5Xp8SZgiVQc1HiJkuhOwXM9PGoQGV925k5L3NPmjO+T HLGQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1783376576; x=1783981376; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=eR/J/KjMv3FFWydwvAFVCsF7iB7TZfoT6HA7WxELzng=; b=mkLSEAH/awN5b0lGgqvQ75NiO6oVcVi5GVVQQc2YYHkiPKU+poDP0ATFrG58rxhW/6 Ol5yTZLIiy1XQasnVx5uh1YUJbdZA+DCF4GX9JQWpObLghTRGgLtPrx30G0jSMQoaJw5 Y6XvjICIqlFw4ikY1820nhnHCi9Z+ETs0MlNDkXsYfI1a1c9ancZKP4nMbRPVMIlBvn5 veaOghmVo2HaaujHNSo7YDqjK3uQnioEPGpCVU/d+v0U4K1q4vi2nc7AgsXA+6xEYKHA oVN5yrXIMSbRExSZ4o9YAW7ViqhzdNRJAzA3ZCKdJwz/ae0cTYfsOeMD1lc1OkKrxMwt YukA== X-Gm-Message-State: AOJu0Yy96+60q/kIFWnToN1mdvBjw6LstK9WW+HWhoLZuICzpQ5FV0wc 6nygYLU2YJDXkXN/11OFlxmnx2Ebpv07TpeyO/hc1WR7r44vG2qT1AVW/3MAcJbvKAKAJjpgbWJ Ohrk1 X-Gm-Gg: AfdE7clc9Z8KlyT6iUMusB5ssU41v71ACTBNrosA95xKrcJhaICIk03ohLHj7Ie5Dsf v3STPWI2k/EF7a3Hob5IdW/pCG+WbP9nZzE/RzCLUOjQ/9lH3k3WZVCE3aperLmBc4zaCXWJA2J u1P482i2KW6wIbZC6NkOMBk0fCXek6PomP+anl9HpZD4eZhpSdX/BYpl07eSuRlICGn88Pr9n0q 8CyO6r/abCNrsT2nZdr/EcrnDlX/bHcbzWiqujfOu0vyUJK39npe4Ypo9dTOdPb4SUws/BGSWhn RNfuPdnNxNrFc2Pa5cAdE68AqprlhTq495cpAK9IhTEilEShv0giChbyuNyjWqwWwJLsqPy/czD YbnzM9QGHFFh2/41aBxVHygjbpAJHKhLyk3wmmdZfuoGTXQdqLAk3E3UavHEQzKAaEbFKB7gjlE rUogHnw14TKC3Q5yxYZ+j0egHNRSzg X-Received: by 2002:a5d:6543:0:b0:475:f0f0:9efc with SMTP id ffacd0b85a97d-47de66cb46bmr1923536f8f.51.1783376575787; Mon, 06 Jul 2026 15:22:55 -0700 (PDT) Received: from inspiron14p-linux ([109.77.44.220]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-47aa039ad21sm27916413f8f.20.2026.07.06.15.22.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Jul 2026 15:22:55 -0700 (PDT) From: Bryan O'Donoghue <bryan.odonoghue@linaro.org> To: libcamera-devel@lists.libcamera.org Cc: bryan.odonoghue@linaro.org, pavel@ucw.cz Subject: [PATCH v6 0/6] libcamera: software_isp: gpu: Add go faster stripes Date: Mon, 6 Jul 2026 23:22:39 +0100 Message-ID: <20260706222245.247396-1-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.54.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: <libcamera-devel.lists.libcamera.org> List-Unsubscribe: <https://lists.libcamera.org/options/libcamera-devel>, <mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe> List-Archive: <https://lists.libcamera.org/pipermail/libcamera-devel/> List-Post: <mailto:libcamera-devel@lists.libcamera.org> List-Help: <mailto:libcamera-devel-request@lists.libcamera.org?subject=help> List-Subscribe: <https://lists.libcamera.org/listinfo/libcamera-devel>, <mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe> Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" <libcamera-devel-bounces@lists.libcamera.org> |
| Series |
|
| Related |
show
|
v6: - Uses std::deque<std::pair<SharedFD, std::unique_ptr<eGLImage>>>; - Robert - Drops SharedFD patch - Robert Link: https://gitlab.freedesktop.org/camera/libcamera-softisp/-/pipelines/1700783 v5: - use activateBindTexture in createTexture2D - Robert Link: https://gitlab.freedesktop.org/camera/libcamera-softisp/-/pipelines/1700395 v4: - Sizes cache as indicated at configure - Ejects oldest entry on cache miss if cache is full. This allows an external application to keep feeding buffers in. - Reverts to using per image dma-buf flags - this is because again we can have heterogeneous sources of buffers. - Takes Barnabas' suggested SharedFD patch - Robert - Accumulates RB as indicated by Milan Link: https://gitlab.freedesktop.org/camera/libcamera-softisp/-/pipelines/1700354 v3: - Fixes a missing switch default from libcamera ci loop - bod v2: - Reverts to debayer_egl specific caching mechanism - Laurent - Pivots on dmabuf handle as key for cache. dmabuf handle must be unique between start() and stop() for eglCreateImageKHR to work - Barnabas - Ensures sizeof cache doesn't exceed the number of expected buffers as discovered during configure() - Barnabas - Drops GL_16F patch - Robert - Drops the "input" name from createInputTexture2D() - Robert - Adds RB as specified by Robert v1: Following on from Robert Mader's ask to bring forward GPUISP multi-pass cache operations to mainline first, I've done some work to enable that. This series implements an input/output texture caching scheme which results in an overall absolute 4.5 millisecond - roughly improvement in performance per processed frame. This is a bit of an odd result as I was expecting to shave a particular % off of each frame in the order of 20% or so. My best guess is that particular paths we are optimising here are around texture generation and these are "fixed costs" on the CPU side. One very welcome outcome of this series is genuine zero-copy on dma-buf paths we can support it on i.e. on paths where the CSI2 and GPU strides agree. The numbers cited in my example are for non dma-buf handle upload and dma-buf handle render-to-texture on the output so, in fact I'd expect to see a much larger improvement on systems where dma-buf handle is used on both paths. As it is on my test reference systems I have a 50% improvement per frame for one system, a 20% improvement on another system or we could view it as a fixed 4.5 millisecond improvement on both. I implemented the cache around V4L2BufferCache as per Barnabas' suggestion, including a fixed cache size. Bryan O'Donoghue (6): libcamera: software_isp: debayer_egl: Pass eglImage as parameter to setShaderVariables libcamera: egl: Add new helper attachTextureToFBO libcamera: egl: Add createOutputTexture2D libcamera: egl: Add activateBindTexture libcamera: egl: Add updateTexture2D libcamera: software_isp: debayer_egl: Implement input/output frame caching mechanism include/libcamera/internal/egl.h | 5 + src/libcamera/egl.cpp | 96 ++++++++++++--- src/libcamera/software_isp/debayer_egl.cpp | 129 ++++++++++++++++----- src/libcamera/software_isp/debayer_egl.h | 13 ++- 4 files changed, 192 insertions(+), 51 deletions(-)