From patchwork Tue Sep 14 23:30:31 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Petter Tomner X-Patchwork-Id: 44999 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id D822C3858407 for ; Tue, 14 Sep 2021 23:34:01 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org D822C3858407 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1631662441; bh=2MnnEtjhNHFShXiue0TIUsE2S3Qm0Tj+9ZiJLlogCJU=; h=To:Subject:Date:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:From; b=gH1/TwxkkC5HypPYooUfAX8BlEGWI3tDeO3C6J/QwysYG/GmGLAp8/iN7JNlDnaVO sl0E2PbucSlamwJawgSy6bkfV8qekpd+J3IoPxWlvfgx8rjeLdz3YM5FSMkdFuqBPX 5dlFdfkJfoZwLubwkEvDZB3JaYfRssZM+RA4KWZg= X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from smtp-4.sys.kth.se (smtp-4.sys.kth.se [IPv6:2001:6b0:1:1300:250:56ff:fea6:2de3]) by sourceware.org (Postfix) with ESMTPS id 8A3B43857801; Tue, 14 Sep 2021 23:30:36 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 8A3B43857801 Received: from smtp-4.sys.kth.se (localhost.localdomain [127.0.0.1]) by smtp-4.sys.kth.se (Postfix) with ESMTP id 3FDFA2848; Wed, 15 Sep 2021 01:30:33 +0200 (CEST) X-Virus-Scanned: by amavisd-new at kth.se Received: from smtp-4.sys.kth.se ([127.0.0.1]) by smtp-4.sys.kth.se (smtp-4.sys.kth.se [127.0.0.1]) (amavisd-new, port 10024) with LMTP id K6bvVGfjhsPy; Wed, 15 Sep 2021 01:30:32 +0200 (CEST) Received: from exdb5.ug.kth.se (exdb5.ug.kth.se [192.168.32.60]) by smtp-4.sys.kth.se (Postfix) with ESMTPS id 977541F3C; Wed, 15 Sep 2021 01:30:32 +0200 (CEST) Received: from exdb6.ug.kth.se (192.168.32.61) by exdb5.ug.kth.se (192.168.32.60) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.858.15; Wed, 15 Sep 2021 01:30:32 +0200 Received: from exdb6.ug.kth.se ([192.168.32.61]) by exdb6.ug.kth.se ([192.168.32.61]) with mapi id 15.02.0858.015; Wed, 15 Sep 2021 01:30:31 +0200 To: "jit@gcc.gnu.org" , "gcc-patches@gcc.gnu.org" Subject: [PATCH 0/2] jit: Add support for complex types Thread-Topic: [PATCH 0/2] jit: Add support for complex types Thread-Index: AQHXqcBkcwvsaBOiiUudH4cBuyREYg== Date: Tue, 14 Sep 2021 23:30:31 +0000 Message-ID: <38cabc705eaf4fe6b26e312b4c5a2cd9@kth.se> Accept-Language: sv-SE, en-US Content-Language: sv-SE X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [192.168.32.250] MIME-Version: 1.0 X-Spam-Status: No, score=-5.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, SPF_HELO_PASS, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Petter Tomner via Gcc-patches From: Petter Tomner Reply-To: Petter Tomner Errors-To: gcc-patches-bounces+patchwork=sourceware.org@gcc.gnu.org Sender: "Gcc-patches" Hi! The following two patches adds support for complex types in libgccjit. The complex types already are in the types enum, however they are not usable. In the patch, to use complex types, the user need to call a option function enabling support. In this way, there will be a linking error if someone tries to use complex types and a too old libgccjit.so, instead of a cryptic out of range enum error message at runtime. Since the types already are in the enum, I saw no better way that wouldn't be confusing.  Patch 1 is implementation and patch 2 is docs and testcases. check-jit runs fine on x64 Debian. Regards, Petter