{"id":16596,"url":"https://patchwork.libcamera.org/api/1.1/patches/16596/?format=json","web_url":"https://patchwork.libcamera.org/patch/16596/","project":{"id":1,"url":"https://patchwork.libcamera.org/api/1.1/projects/1/?format=json","name":"libcamera","link_name":"libcamera","list_id":"libcamera_core","list_email":"libcamera-devel@lists.libcamera.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20220712130138.25084-1-naush@raspberrypi.com>","date":"2022-07-12T13:01:38","name":"[libcamera-devel] libcamera: base: Remove ARM clang-11 compile error","commit_ref":null,"pull_url":null,"state":"superseded","archived":false,"hash":"5dbadac1d42605e75d9bd87ccb1846c0d5463bab","submitter":{"id":34,"url":"https://patchwork.libcamera.org/api/1.1/people/34/?format=json","name":"Naushir Patuck","email":"naush@raspberrypi.com"},"delegate":null,"mbox":"https://patchwork.libcamera.org/patch/16596/mbox/","series":[{"id":3274,"url":"https://patchwork.libcamera.org/api/1.1/series/3274/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=3274","date":"2022-07-12T13:01:38","name":"[libcamera-devel] libcamera: base: Remove ARM clang-11 compile error","version":1,"mbox":"https://patchwork.libcamera.org/series/3274/mbox/"}],"comments":"https://patchwork.libcamera.org/api/patches/16596/comments/","check":"pending","checks":"https://patchwork.libcamera.org/api/patches/16596/checks/","tags":{},"headers":{"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\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 480C3BE173\n\tfor <parsemail@patchwork.libcamera.org>;\n\tTue, 12 Jul 2022 13:01:46 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id AF5AD6330B;\n\tTue, 12 Jul 2022 15:01:45 +0200 (CEST)","from mail-wr1-x433.google.com (mail-wr1-x433.google.com\n\t[IPv6:2a00:1450:4864:20::433])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 9E68E60402\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 12 Jul 2022 15:01:43 +0200 (CEST)","by mail-wr1-x433.google.com with SMTP id q9so11073206wrd.8\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 12 Jul 2022 06:01:43 -0700 (PDT)","from naush-laptop.localdomain ([93.93.133.154])\n\tby smtp.gmail.com with ESMTPSA id\n\tk1-20020adfd841000000b0021d73772c87sm8003330wrl.91.2022.07.12.06.01.42\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tTue, 12 Jul 2022 06:01:42 -0700 (PDT)"],"DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1657630905;\n\tbh=JStbRSRwvZS2io6oP4MAIWekhcAbet7xYKl+oXsenZo=;\n\th=To:Date:Subject:List-Id:List-Unsubscribe:List-Archive:List-Post:\n\tList-Help:List-Subscribe:From:Reply-To:From;\n\tb=QVUvfzeieOcA6W+//8hXPs4JBQs+ckXpLPbPFLxdEY5RZhdy0HSq224GyWepOHPoI\n\t9i3mSAQU+G0LNJ38ck5rSkjhv4VUeBbE4CXTlOXAueDvW4MU6y8xXTAYw0ImyIEN0+\n\tryZyh6vGT2ro64NjFdPGOZsCqLZJcTaYFpMnXMFnVeRC4+fSJA5RWB6k3qG9GcUINw\n\tsO04faJJU34N2tJmGC1mdtTyxi91GBBWxbo4+HJPb6GiKxcY0IVQB+vc4G20xd3hvC\n\t8REwJdxDKMv9mLaN5wVy2zMbREtiNpNj3jPsilT1I8w3QLudsCE58tIA4rqfhNiVKL\n\tzlAQGN3zeIU2A==","v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=raspberrypi.com; s=google;\n\th=from:to:cc:subject:date:message-id:mime-version\n\t:content-transfer-encoding;\n\tbh=/CCW559pr/f+vbcPF1kkmI+KJX6ehgR1gePaGHapvUE=;\n\tb=V9JfGLKcDyo9vPvfZjFIb/Bu4kEoxbmZJ31rKHJ1wHycuBMliky3Qs2gulcg65jxJ1\n\ttcWM02pHobWCBPSvDNKnY/fKre8BxHLneaNo1xGo9Y948dWQr9rYn7uVT4VKVj7ejCwB\n\t2og5gHUjUJR0afAcxDPy74Zak4vlllWGVR2DMKZFgOOJxONyvyYs0hyqhlRhqFebzKd7\n\tMoqbPoYjVocoSdHTrnFsLS1s/JDK3XKZ8NGKukdZHKpEP12fzPl92sX8NkntwTX7DsqS\n\tpodwFre9QLOqLPmgWYBK3JNVO38UuyPjLPyw1+hBkCoL8G1de3KXdU6Jx5jMRbJwbS1Q\n\tTwdA=="],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (2048-bit key; \n\tunprotected) header.d=raspberrypi.com\n\theader.i=@raspberrypi.com\n\theader.b=\"V9JfGLKc\"; dkim-atps=neutral","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20210112;\n\th=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version\n\t:content-transfer-encoding;\n\tbh=/CCW559pr/f+vbcPF1kkmI+KJX6ehgR1gePaGHapvUE=;\n\tb=Qg3gWTr0AJP3Kj54ef4Nt9qg/fM//Hp4hQ1ToAQNM+x6jI7/YV7QYtiKat7jRT7+ar\n\tmn6vXvZK6M8E8eUbg/WuSTopPsE0TwV62doSRKEBT+x6seh3BXq5KTJLhu7SJ0gOgJRW\n\t+KS0jjOJ6NfQWJAziNgo/2iacjjNoxi12EdqzjFJSXHssP+8Pgth9SWWjX28rWM5Q5nG\n\tyOelYGQKm7uLJ9cG8kFZ/CtsldWyVcoPAb5yKT5gOTm5leotMj7nTuqIjhovkpJYteG1\n\t/MKmHvaiTBUloZ0os8spD9T40PxS1MKik1apB4P/T80eMQRponXl1qZO3fnrwDnpaW26\n\trbKg==","X-Gm-Message-State":"AJIora9HdX/IGK1BZvdfnlHcW+XyZQvRG//dfn6Z2tmzvh8/TJlqTNEX\n\tzGMXaHgpZ58I9Lu2uqcSgPnlGTjriTLgTg==","X-Google-Smtp-Source":"AGRyM1vAVP9R5iWJHswDrFCADfWp6WG0EoHLmCKf+jcxnTnPLW1+a1S0UhANDZpZUQV9lYETIkia7g==","X-Received":"by 2002:a5d:4f02:0:b0:21d:63f6:380c with SMTP id\n\tc2-20020a5d4f02000000b0021d63f6380cmr21993203wru.635.1657630903011; \n\tTue, 12 Jul 2022 06:01:43 -0700 (PDT)","To":"libcamera-devel@lists.libcamera.org","Date":"Tue, 12 Jul 2022 14:01:38 +0100","Message-Id":"<20220712130138.25084-1-naush@raspberrypi.com>","X-Mailer":"git-send-email 2.25.1","MIME-Version":"1.0","Content-Transfer-Encoding":"8bit","Subject":"[libcamera-devel] [PATCH] libcamera: base: Remove ARM clang-11\n\tcompile error","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>,\n\t<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>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","From":"Naushir Patuck via libcamera-devel\n\t<libcamera-devel@lists.libcamera.org>","Reply-To":"Naushir Patuck <naush@raspberrypi.com>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"},"content":"Compiling backtrace.cpp produces the follwing error with the ARM clang-11 (and\nlater) compiler:\n\n--------------------\n../src/libcamera/base/backtrace.cpp:195:12: error: use of SP or PC in the list is deprecated [-Werror,-Winline-asm]\n        int ret = unw_getcontext(&uc);\n                  ^\n/usr/include/arm-linux-gnueabihf/libunwind-common.h:114:29: note: expanded from macro 'unw_getcontext'\n                                        ^\n/usr/include/arm-linux-gnueabihf/libunwind-arm.h:270:5: note: expanded from macro 'unw_tdep_getcontext'\n    \"stmia %[base], {r0-r15}\"                                           \\\n    ^\n<inline asm>:1:2: note: instantiated into assembly here\n        stmia r0, {r0-r15}\n--------------------\n\nSuppress this compilation error with a clang specific pragma around the\noffending statements.\n\nFurther information about this error can be found here:\nhttps://github.com/dotnet/runtime/issues/5\n\nSigned-off-by: Naushir Patuck <naush@raspberrypi.com>\n---\n src/libcamera/base/backtrace.cpp | 10 ++++++++++\n 1 file changed, 10 insertions(+)","diff":"diff --git a/src/libcamera/base/backtrace.cpp b/src/libcamera/base/backtrace.cpp\nindex 483492c390c3..b8ae2f6dc331 100644\n--- a/src/libcamera/base/backtrace.cpp\n+++ b/src/libcamera/base/backtrace.cpp\n@@ -191,11 +191,21 @@ __attribute__((__noinline__))\n bool Backtrace::unwindTrace()\n {\n #if HAVE_UNWIND\n+\n+#if __clang__\n+#pragma clang diagnostic push\n+#pragma clang diagnostic ignored \"-Winline-asm\"\n+#endif\n+\n \tunw_context_t uc;\n \tint ret = unw_getcontext(&uc);\n \tif (ret)\n \t\treturn false;\n \n+#if __clang__\n+#pragma clang diagnostic pop\n+#endif\n+\n \tunw_cursor_t cursor;\n \tret = unw_init_local(&cursor, &uc);\n \tif (ret)\n","prefixes":["libcamera-devel"]}