From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx0a-00069f02.pphosted.com (mx0a-00069f02.pphosted.com [205.220.165.32]) by sourceware.org (Postfix) with ESMTPS id 0160B3858D28 for ; Fri, 6 Jan 2023 07:58:14 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 0160B3858D28 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=oracle.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=oracle.com Received: from pps.filterd (m0246627.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 3061Z40g031462 for ; Fri, 6 Jan 2023 07:58:14 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : content-type : content-transfer-encoding : mime-version; s=corp-2022-7-12; bh=CPDhOaoJuQmkxs0GQ/oWNYO/ejuOxeCaPK9wjmtz78Y=; b=dAATpaG+v241xlUhyD4cI5nYn4YS7uyT8/zct/ZFAJ0X+uZ5PQF1Cry65YikoT4BQiRp nJIakXZh4ZHg1crLIVScPDV2xwf+flBWf8UXadGnY7BjFOUEDcIzK5wNOaC8EQvt2jDJ uk7jIqUsSE6SzsvONkwmqn5Fs0QQL3iKUqCtE7lmq8YPJK+KlR4ZNfT3WKkCuZLsgbRx D7fDqzywUBXrQuQmOuv1ThEWtQCdFKWOzS9hZfsCfuoHZBLvkoK9iXWR99H6q2gMQiJ/ cbIBxwj9LA4K2sHcpxzhe1mBjW56CSGq+0FJS8TCxCasueN9mzKVUhzqGWTceO2tn2ed 2w== Received: from iadpaimrmta01.imrmtpd1.prodappiadaev1.oraclevcn.com (iadpaimrmta01.appoci.oracle.com [130.35.100.223]) by mx0b-00069f02.pphosted.com (PPS) with ESMTPS id 3mtbp12p0x-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Fri, 06 Jan 2023 07:58:13 +0000 Received: from pps.filterd (iadpaimrmta01.imrmtpd1.prodappiadaev1.oraclevcn.com [127.0.0.1]) by iadpaimrmta01.imrmtpd1.prodappiadaev1.oraclevcn.com (8.17.1.5/8.17.1.5) with ESMTP id 3067ZhSd007461 for ; Fri, 6 Jan 2023 07:58:12 GMT Received: from nam11-dm6-obe.outbound.protection.outlook.com (mail-dm6nam11lp2169.outbound.protection.outlook.com [104.47.57.169]) by iadpaimrmta01.imrmtpd1.prodappiadaev1.oraclevcn.com (PPS) with ESMTPS id 3mwft0rknu-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Fri, 06 Jan 2023 07:58:12 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=YZ0F9RUwQ9LuE3GWrL6LbVL2GxcSmFflJUtjRgvfvJ7HMKLb3eqQpHeFt9LoapvMMuaEj4COo9GXeR4CxPkrJYb2WSUrlFnGHNHbDmVKcd1Eml9fz4BK+a0joi0705sHOJ/L0yDRSOQRVD1bMPZ9bveI0ew3pBBqflpMdvDP2QhAGND74tU+YnrZ7tXpWyn5Hp9Ee/qB16wWFj8Ifoz6zczteuCHR7J7/msMrlW65dsdVXET9vnqJcTQtulYtyGYkTL6WYUfZ8sPzA7fEbQfquVPMG/F0y2wLOkxcUytbabUiDfzMvOwGCffUVNfOMHSf9N+O8fQBYHhBtUwAekPfg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=CPDhOaoJuQmkxs0GQ/oWNYO/ejuOxeCaPK9wjmtz78Y=; b=NHunmfYZrGaWfR0k9DYKChkKANQTovSEeqjW4FGVFfgK5rYVgvo3lnAXGyiGev10sBEOyWWTG5kHJwtAKN5kyHPyU8RO5Yz6bXPQY4OotZ/95VZpMnQ+Ju5HQp9l9OVm9kJ+EquGbzOp2OJ2D5E7HI+eQi4CFla+f1g0egKUstSMeCL3XBvojaW9JDHzofCPdK+tn2u6bvH+MDdoZnew5Hi3ZhNK0BLts7F/7N05uQzcGJmCGw/NGD+KPOcW6DntAWIZzeJOdL/Mksfibmpj/w+Db5G4cxhtnSd1qiIsFT7hfgHgmlJzPiGvzxm597gbpAZJENxsBfAjq72OYa31aQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oracle.com; dmarc=pass action=none header.from=oracle.com; dkim=pass header.d=oracle.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.onmicrosoft.com; s=selector2-oracle-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=CPDhOaoJuQmkxs0GQ/oWNYO/ejuOxeCaPK9wjmtz78Y=; b=GOqPrd0/NyHseYiJNB8QII8YG/Rs0Ht/Aahiqdot/S4B11gNb4abYmecHINACs6LlCz5bHyEGPXmrhGnvZLv3X2k0XmIYFykEFDMcpItXm/JYMmc8EkavpfdspRhN3KEwz5n64ZUEnhq4lvgCatX+5dyalnMsubCUtKsDt9Cyvg= Received: from MWHPR10MB1407.namprd10.prod.outlook.com (2603:10b6:300:23::20) by PH0PR10MB5546.namprd10.prod.outlook.com (2603:10b6:510:d9::8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5944.19; Fri, 6 Jan 2023 07:58:10 +0000 Received: from MWHPR10MB1407.namprd10.prod.outlook.com ([fe80::70df:cb31:cf08:5b12]) by MWHPR10MB1407.namprd10.prod.outlook.com ([fe80::70df:cb31:cf08:5b12%9]) with mapi id 15.20.5944.019; Fri, 6 Jan 2023 07:58:09 +0000 From: "Guillermo E. Martinez" To: binutils@sourceware.org Cc: jose.marchesi@oracle.com, "Guillermo E. Martinez" Subject: [PATCH] bpf: fix error conversion from long unsigned int to unsigned int [-Werror=overflow] Date: Fri, 6 Jan 2023 01:58:16 -0600 Message-Id: <20230106075816.387489-1-guillermo.e.martinez@oracle.com> X-Mailer: git-send-email 2.39.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-ClientProxiedBy: DM6PR06CA0037.namprd06.prod.outlook.com (2603:10b6:5:54::14) To MWHPR10MB1407.namprd10.prod.outlook.com (2603:10b6:300:23::20) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: MWHPR10MB1407:EE_|PH0PR10MB5546:EE_ X-MS-Office365-Filtering-Correlation-Id: 7a33744f-de3b-4522-f4a9-08daefbbc093 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: dGbYvxnikF+pgPDQWZfvgQmUgovgPMBAjNNjHWz0mnGPNkf0aXFaLtlxXmjuHXGotorAyrefZd7CoRpb6LoLCMIMA0Mrl812U0JWZui0fAk9NvU9rPDdBddk3v7sDcBb3vuud2tK/C7B4Bo60PXnit6EwwsxrTJVCrn6hq6YsTOLaBqgIIyzFn9XhUCyiLo3nAlGDiU/rWHBz/AXjTrJGu8UBG3zqkiKHiCeAuJONInok5QzCTlSoh50iSHjpOzhpNDIhzD4O8xqVYBxgjF06k+7xGkfxhcUJThDBIoSm2p4hCxVO2mUZwMCeknsh2qbCwCNPVNRiHyIaVJ8Oh0eMXTHs7A5HWCA5Tt8lIld7k/HfwaxN6TJHCxgP/o+OpTFIehaKt4jT/ib3X0maFAwEgTAvEhjc/7P+es0dkO3PhCTXBx+/C4id6gEwvBP2cjy+Me6+3smJ4txxk3eJ4RKpsg8FlRTF9AEx6nTugjmtlUXnLArkfsqHwZRoPJ2V8xUwVGMeaJyjANtW60OfV6NTOI875ilH1ahBAEuGS4LpKayakcsgnut3jqR8IcQMyGAjpo1LWWxUI8+3RyQHnZeUV2cDnN+titeNtFXq7CQqa6IYe1wAPbIiZ+bydY5efA+1cRBdfSricdnvGCYFiddwQ== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:MWHPR10MB1407.namprd10.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230022)(39860400002)(366004)(396003)(136003)(376002)(346002)(451199015)(86362001)(83380400001)(41300700001)(8936002)(2906002)(38100700002)(30864003)(5660300002)(4326008)(186003)(6512007)(6666004)(107886003)(6506007)(1076003)(2616005)(316002)(66476007)(66946007)(6486002)(6916009)(66556008)(478600001)(8676002)(103116003)(36756003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?K0F3SE4yWmJBWmRXcXdiRzUybkU5SEtFWUNsZzBrbGkwOEZFT2dQeHplRWRB?= =?utf-8?B?L2doQTNqR3hNeGN1SFZXNWhRVFRaM3BIU2Nmd25Wa0Z4bHJyUm5FcXlUYjBq?= =?utf-8?B?KzRIK3lEMjNGT3ppbm83ZDJiZHlYTFpjRzBVbEd1VkkvZStZMitCcHRrQWFy?= =?utf-8?B?WE5uNmdnaHFhNHNqdDIwTGNvMGdzai9wb2l1aEtrM0NaQkJTeEhUaG5OVGNu?= =?utf-8?B?UlpjWDZEc0xDWXVxcGFUOUk3eUpZZ2hWK1E2TjZQajhRUVg1TDNUanJVQjZh?= =?utf-8?B?akJ0SzlVSlZjTERtVzZMblkrR3VmS1RwaGdIL1U0TC9yRXJkZWd3WmttSmpC?= =?utf-8?B?V09QbEFadE55RG5ZZHlCL2FVTGRjYWQyQ1g1djJpSHVpemRrZzU5SlFhWThr?= =?utf-8?B?Wndhc0tOdlVMM1VuWUpqVmxEdkVDMFVOMkhPVCtlTGpQQ3BsLzA5N0w1d3lt?= =?utf-8?B?ZW5Yd1VzLy9sckNmem96N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egHYAPyshx8ZJPrCZzBAWLxgTb1Y3Fm3zXRd22sDDi5df6grNIfEN1C+bvO3Y7nMoUtI36CpKIR9WIK8tHOo3g9I54tju8PtUs+EfWxe3ZvlyGx5SXPJZg66E5LflW9wTh9KO2/M04xFa0ZCB0Xzm5QmBu80MLYeaBMQ3JBdMFcu19FbHF+YqK0wEA6KxiTQNK6esZXA6lhR1wHBM36Wk+GBWZHq0/RlNE019+OfkS0e7RUe1IkDP2CN6zPbG14hhBDGFKQz4QqKUijIMiOpYnLtEhvL/Gx1FRjVsW1FvIWKbqqnYVOXS7H3EUXkdvubIbN6VrQOz/eMNDBkDtSpCL23J05Oov67ZDb1OwoGIAe96RQoP5BQbwvGgKUSy565Dcart9yAGZS+w3K6RA761bvS+te5bHZqkhIXD6OxtM39jUE0eu2PA+crusxILyjUT3ZpBc4GQDBc+eNqQCUJKMSLpL/68cT7xwOGO8liryiW19m3n6KcAG6HS6c2xTlDqLpCtxreRsWC/yhhFVidPQG/CPnMh3FAp0cVUj8hpsgiuqxLEIV2Fg+LYEHROrPKkoYenDkR9ncXU7ebXLR451ftrjPXlIsmMb2kwb/r8oX8yd3VaFygcdJ9HDLYjGZDiiQWYMHrssZQcF6l8Aa6Mkx0diXL3IN4thYVM2Gw44SGazK/5Kh+vp3Ha3ClMI3w9siKRDEp4YwWGSz+CYBP7/XR2H1gOr81+j X-OriginatorOrg: oracle.com X-MS-Exchange-CrossTenant-Network-Message-Id: 7a33744f-de3b-4522-f4a9-08daefbbc093 X-MS-Exchange-CrossTenant-AuthSource: MWHPR10MB1407.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Jan 2023 07:58:09.8003 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 4e2c6054-71cb-48f1-bd6c-3a9705aca71b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: yBKc+eMjtE9jU18KeVe/RDK+IC7S17ek8Ll4YcwHF5AXozxMn3afGmJUKLI888b2c2Yn7PKBwFBN6MyN0NrAWzVMZ+IQrGIxqQBEm8AQqUU= X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH0PR10MB5546 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.923,Hydra:6.0.545,FMLib:17.11.122.1 definitions=2023-01-06_03,2023-01-05_02,2022-06-22_01 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 mlxscore=0 mlxlogscore=732 adultscore=0 spamscore=0 malwarescore=0 bulkscore=0 phishscore=0 suspectscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2212070000 definitions=main-2301060062 X-Proofpoint-GUID: 5eM0oZCvoeEWzcp4vMczaCzWj7W3RSjc X-Proofpoint-ORIG-GUID: 5eM0oZCvoeEWzcp4vMczaCzWj7W3RSjc X-Spam-Status: No, score=-13.1 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,RCVD_IN_DNSWL_LOW,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE,TXREP,UPPERCASE_50_75 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: Hello, This patch is meant to fix compiling errors when maintainer mode is enable to BPF target. Please let me know your comments, I'll really appreciate them. Kind regards, guillermo -- Regenerate BPF target using the maintainer mode emits: .../opcodes/bpf-opc.c:57:11: error: conversion from ‘long unsigned int’ to ‘unsigned int’ changes value from ‘18446744073709486335’ to ‘4294902015’ [-Werror=overflow] 57 | 64, 64, 0xffffffffffff00ff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_CODE) }, { F (F_DSTLE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } The use of a narrow size to handle the mask CGEN in instruction format is causing this error. Additionally eBPF `call' instructions constructed by expressions using symbols (BPF_PSEUDO_CALL) emits annotations in `src' field of the instruction, used to identify BPF target endianness. cpu/ * bpf.cpu (define-call-insn): Remove `src' field from instruction mask. include/ *opcode/cge.h (CGEN_IFMT): Adjust mask bit width. opcodes/ * bpf-opc.c: Regenerate. --- cpu/bpf.cpu | 2 +- include/opcode/cgen.h | 2 +- opcodes/bpf-opc.c | 54 +++++++++++++++++++++++-------------------- 3 files changed, 31 insertions(+), 27 deletions(-) diff --git a/cpu/bpf.cpu b/cpu/bpf.cpu index 13dde7094c8..2ae74fc4c18 100644 --- a/cpu/bpf.cpu +++ b/cpu/bpf.cpu @@ -768,7 +768,7 @@ "call" (endian-isas x-endian) "call $disp32" - (+ disp32 (f-offset16 0) (f-regs 0) + (+ disp32 (f-offset16 0) (.sym src x-endian) ((.sym f-dst x-endian) 0) OP_CLASS_JMP OP_SRC_K OP_CODE_CALL) (c-call VOID "bpfbf_call" disp32 (ifield (.sym f-src x-endian))) diff --git a/include/opcode/cgen.h b/include/opcode/cgen.h index 36b88f1b5fe..6c0732b4b25 100644 --- a/include/opcode/cgen.h +++ b/include/opcode/cgen.h @@ -914,7 +914,7 @@ typedef struct Each insn's value is stored with the insn. The first step in recognizing an insn for disassembly is (opcode & mask) == value. */ - CGEN_INSN_INT mask; + CGEN_INSN_LGUINT mask; #define CGEN_IFMT_MASK(ifmt) ((ifmt)->mask) /* Instruction fields. diff --git a/opcodes/bpf-opc.c b/opcodes/bpf-opc.c index a6d8a7dd3ca..1cc06f7cbf6 100644 --- a/opcodes/bpf-opc.c +++ b/opcodes/bpf-opc.c @@ -50,99 +50,103 @@ static const CGEN_IFMT ifmt_empty ATTRIBUTE_UNUSED = { }; static const CGEN_IFMT ifmt_addile ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_CODE) }, { F (F_DSTLE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xfffff0ff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_CODE) }, { F (F_DSTLE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_addrle ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_CODE) }, { F (F_DSTLE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xffffffffffff00ff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_CODE) }, { F (F_DSTLE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_negle ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_CODE) }, { F (F_DSTLE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xfffffffffffff0ff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_CODE) }, { F (F_DSTLE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_addibe ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_CODE) }, { F (F_SRCBE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xffff0fff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_CODE) }, { F (F_SRCBE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_addrbe ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_CODE) }, { F (F_SRCBE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xffffffffffff00ff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_CODE) }, { F (F_SRCBE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_negbe ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_CODE) }, { F (F_SRCBE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xffffffffffff0fff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_CODE) }, { F (F_SRCBE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_endlele ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_CODE) }, { F (F_DSTLE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xfffff0ff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_CODE) }, { F (F_DSTLE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_endlebe ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_CODE) }, { F (F_SRCBE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xffff0fff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_CODE) }, { F (F_SRCBE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_lddwle ATTRIBUTE_UNUSED = { - 64, 128, 0xff, { { F (F_IMM64) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_MODE) }, { F (F_OP_SIZE) }, { F (F_DSTLE) }, { F (F_OP_CLASS) }, { 0 } } + 64, 128, 0xfffff0ff, { { F (F_IMM64) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_MODE) }, { F (F_OP_SIZE) }, { F (F_DSTLE) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_lddwbe ATTRIBUTE_UNUSED = { - 64, 128, 0xff, { { F (F_IMM64) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_MODE) }, { F (F_OP_SIZE) }, { F (F_SRCBE) }, { F (F_OP_CLASS) }, { 0 } } + 64, 128, 0xffff0fff, { { F (F_IMM64) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_MODE) }, { F (F_OP_SIZE) }, { F (F_SRCBE) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_ldabsw ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_REGS) }, { F (F_OP_MODE) }, { F (F_OP_SIZE) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xffffffff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_REGS) }, { F (F_OP_MODE) }, { F (F_OP_SIZE) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_ldindwle ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_MODE) }, { F (F_OP_SIZE) }, { F (F_DSTLE) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xffff0fff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_MODE) }, { F (F_OP_SIZE) }, { F (F_DSTLE) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_ldindwbe ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_MODE) }, { F (F_OP_SIZE) }, { F (F_SRCBE) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xfffff0ff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_MODE) }, { F (F_OP_SIZE) }, { F (F_SRCBE) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_ldxwle ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_MODE) }, { F (F_OP_SIZE) }, { F (F_DSTLE) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xffffffff000000ff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_MODE) }, { F (F_OP_SIZE) }, { F (F_DSTLE) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_ldxwbe ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_MODE) }, { F (F_OP_SIZE) }, { F (F_SRCBE) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xffffffff000000ff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_MODE) }, { F (F_OP_SIZE) }, { F (F_SRCBE) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_stble ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_MODE) }, { F (F_OP_SIZE) }, { F (F_DSTLE) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xf0ff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_MODE) }, { F (F_OP_SIZE) }, { F (F_DSTLE) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_stbbe ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_MODE) }, { F (F_OP_SIZE) }, { F (F_SRCBE) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xfff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_MODE) }, { F (F_OP_SIZE) }, { F (F_SRCBE) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_jeqile ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_CODE) }, { F (F_DSTLE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xf0ff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_CODE) }, { F (F_DSTLE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_jeqrle ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_CODE) }, { F (F_DSTLE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xffffffff000000ff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_CODE) }, { F (F_DSTLE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_jeqibe ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_CODE) }, { F (F_SRCBE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xfff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_CODE) }, { F (F_SRCBE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_jeqrbe ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_CODE) }, { F (F_SRCBE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xffffffff000000ff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_CODE) }, { F (F_SRCBE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_callle ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_REGS) }, { F (F_OP_CODE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xffff0fff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_SRCLE) }, { F (F_OP_CODE) }, { F (F_DSTLE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } +}; + +static const CGEN_IFMT ifmt_callbe ATTRIBUTE_UNUSED = { + 64, 64, 0xfffff0ff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_DSTBE) }, { F (F_OP_CODE) }, { F (F_SRCBE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_ja ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_REGS) }, { F (F_OP_CODE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xffffffff0000ffff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_REGS) }, { F (F_OP_CODE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } }; static const CGEN_IFMT ifmt_exit ATTRIBUTE_UNUSED = { - 64, 64, 0xff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_REGS) }, { F (F_OP_CODE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } + 64, 64, 0xffffffffffffffff, { { F (F_IMM32) }, { F (F_OFFSET16) }, { F (F_REGS) }, { F (F_OP_CODE) }, { F (F_OP_SRC) }, { F (F_OP_CLASS) }, { 0 } } }; #undef F @@ -1646,7 +1650,7 @@ static const CGEN_OPCODE bpf_cgen_insn_opcode_table[MAX_INSNS] = { { 0, 0, 0, 0 }, { { MNEM, ' ', OP (DISP32), 0 } }, - & ifmt_callle, { 0x85 } + & ifmt_callbe, { 0x85 } }, /* call $dstle */ { -- 2.39.0