From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.3 required=5.0 tests=MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 26577 invoked from network); 28 Dec 2020 17:02:04 -0000 Received: from mother.openwall.net (195.42.179.200) by inbox.vuxu.org with ESMTPUTF8; 28 Dec 2020 17:02:04 -0000 Received: (qmail 17686 invoked by uid 550); 28 Dec 2020 17:01:58 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Reply-To: musl@lists.openwall.com Received: (qmail 17665 invoked from network); 28 Dec 2020 17:01:57 -0000 Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 13.4 \(3608.120.23.2.4\)) From: Shiz In-Reply-To: <865734a3-e4c6-eb06-5855-db74c00fb071@darkkirb.de> Date: Mon, 28 Dec 2020 18:01:45 +0100 Cc: darkkirb@darkkirb.be Content-Transfer-Encoding: quoted-printable Message-Id: References: <6106be97-2c82-75c0-ad88-2e49b17c68ee@darkkirb.de> <20201227230554.ddflrnbmyvjccj4n@gmail.com> <20201228005632.rezxjuehsgmr5ira@gmail.com> <0326d35a-4c1d-3d25-1917-166e5b580062@darkkirb.de> <865734a3-e4c6-eb06-5855-db74c00fb071@darkkirb.de> To: musl@lists.openwall.com X-Mailer: Apple Mail (2.3608.120.23.2.4) Subject: Re: [musl] [PATCH] Add support for LLVM's Control Flow Integrity (V2) Hi, It seems to me guarding all of those with #ifdef __clang__ is not the = optimal approach. What if another compilers decides to pick up the spec, or an older = non-CFI Clang is used to compile? I think it's more logical to check the = no_sanitize attribute with a functional test (like __has_attribute), and to just apply the = used attribute unconditionally. - Shiz