From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTPS id E4AA8385B537 for ; Tue, 21 Feb 2023 12:02:56 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org E4AA8385B537 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1676980976; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=v436M984gQU52aCrqEOYYht7BQWftJj1iZXNYe2sz3E=; b=ExJCr9JiPwRMrrktReYZfF7noLSjFFILI4/CRyi6CUxf8NO5O2WkedNgTVTAkEZer4p4Nm pxtCW8DCr+8aNDJVEOpPEqWEO9Rmk9paLIZ2/qQPWvNx/TvhO/ExDFjfL0Ll2MJ+ZUu3TP Aforg1VWg42qM4WhOdoel/04+RfeFPw= Received: from mail-wm1-f72.google.com (mail-wm1-f72.google.com [209.85.128.72]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_128_GCM_SHA256) id us-mta-610-FntVDe6AOMqscqItWvef_Q-1; Tue, 21 Feb 2023 07:02:55 -0500 X-MC-Unique: FntVDe6AOMqscqItWvef_Q-1 Received: by mail-wm1-f72.google.com with SMTP id e22-20020a05600c219600b003e000facbb1so1871965wme.9 for ; Tue, 21 Feb 2023 04:02:55 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:subject:from:references:to :content-language:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=v436M984gQU52aCrqEOYYht7BQWftJj1iZXNYe2sz3E=; b=K9s1ukMgVDxtXbc0gbEJkDN/V0tYzB2tbv1Slj0qEySGkYNZEbg1R6XK8mODxaoVoZ P5XfhiXEtMZN2a2LfSjZu3MwwcKhr+gozwnaVbfaX8IHWj3o7ieXvoQVUYW4m3ezSnqV HCVXcgZ7GMWqVhpcTIrGfoeiVcSHb9h14Ebf9qlfG0AwOmXsmy3BUV0GsFjCQNbv2xoi Vab3WTsWWM9GvzHfOyGvh8P2t0T24tLlm5aaxPH2l9SDcUGxQMqY94EmPVvNFfofHBLm TpfA0Ied2eyhP/6nj4M3f96KU9Qac0nlnUiNGOEM2phC/7rNJVSgXgjUMGR/jlMbG7Ve EAcA== X-Gm-Message-State: AO0yUKW3nL/8tMWKvuLM9ZKi+Gdi+IVAP8B5qAeZujVpb0p/votFj49d Bs7freiie0/sK2uD6gHFW6GnhWDOJybh43keRKyCkxRahKa/QNL1IlJek/bUN92WyEJopL721N9 pNzruKONl8psx+3neE59Bq+E= X-Received: by 2002:a05:600c:984:b0:3dc:561a:79d8 with SMTP id w4-20020a05600c098400b003dc561a79d8mr3801870wmp.35.1676980973766; Tue, 21 Feb 2023 04:02:53 -0800 (PST) X-Google-Smtp-Source: AK7set/7jLrav7CkVqiwPKwgVzTCk10fMYSBcxupoWLlRRUmrXYqgHaPXWcsSRN2IGln01XSyTnzxg== X-Received: by 2002:a05:600c:984:b0:3dc:561a:79d8 with SMTP id w4-20020a05600c098400b003dc561a79d8mr3801852wmp.35.1676980973480; Tue, 21 Feb 2023 04:02:53 -0800 (PST) Received: from [192.168.1.18] ([79.123.86.193]) by smtp.gmail.com with ESMTPSA id n13-20020a5d4c4d000000b002c55de1c72bsm8110101wrt.62.2023.02.21.04.02.52 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 21 Feb 2023 04:02:53 -0800 (PST) Message-ID: Date: Tue, 21 Feb 2023 12:02:52 +0000 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.7.1 To: Ulf Samuelsson , binutils@sourceware.org References: <20230219194549.22554-1-binutils@emagii.com> <20230219194549.22554-2-binutils@emagii.com> From: Nick Clifton Subject: Re: [PATCH v4 0/5] Add support for CRC64 generation in linker In-Reply-To: X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Language: en-GB Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-3.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Hi Ulf, > Fourth patchset. > Get rid of binaries in testsuite. Thanks. I do wonder if it would be possible to simplify some of the extensions to the linker script syntax, in order to make it easier to use and to allow for future extensions. For example: DIGEST "algorithm" ( start_symbol, end_symbol ) So "algorithm" could be "CRC" or "CRC32" or "CRC64" or "CRC64-WE" or "CRC TABLE" or any of the other algorithms/features that you want to support[1]. And more could be added in the future without having to update the linker script syntax. If the algorithm needs extra data apart from the start and end symbols then this could be included in the name, eg: DIGEST "CRC64-POLY-0xDEADBEEFDEADBEEF" (ecc_start , ecc_end) I would also suggest that functionality should not be restricted to just the .text section, but that it should work for any section. (It is reasonable to restrict it to only working inside a single section however). > An algorithm typically needs > *init__tab( poly ) > calc__inv( const unsigned char *input_str, size_t num_bytes ); > calc_ ( const unsigned char *input_str, size_t num_bytes ); > void lang_add__syndrome(bool invert, bfd_vma poly) > void lang_add__table(void) Since there are going to be several different versions of these functions, and possibly more to come in the future, I think that it would be best to put them into a new file. eg lddigest.c This might also make it easier for other linkers to make use of the code, should they decide to implement a similar feature. I am going to post some individual reviews of the patches as well, but I wanted to give my overall impressions here. Cheers Nick [1] Well except for TIMESTAMP and DEBUG ON/OFF which are valid new features in their own rights.