From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id YO+JK3L+PGAGJAAAWB0awg (envelope-from ) for ; Mon, 01 Mar 2021 09:47:14 -0500 Received: by simark.ca (Postfix, from userid 112) id 9D0CD1EF7E; Mon, 1 Mar 2021 09:47:14 -0500 (EST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on simark.ca X-Spam-Level: X-Spam-Status: No, score=0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,MAILING_LIST_MULTI,MSGID_FROM_MTA_HEADER,RDNS_NONE, URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.2 Received: from sourceware.org (unknown [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id D70AE1E590 for ; Mon, 1 Mar 2021 09:47:12 -0500 (EST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 244FF393A406; Mon, 1 Mar 2021 14:47:12 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 244FF393A406 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1614610032; bh=pW/7a+X/xJTRyjx6gfr3GWGjhY9LSegM0viCdUSFbKk=; h=To:Subject:Date:In-Reply-To:References:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=fmWfFgX60qs9MEgTdsvLBA6NyylKMjGEpeNt5WLOrGyUjJYxmF161V+mnWSiGLeEr mEbMMTr42kHO8aLjqo3DFAqvzsg2naE5JfFJUysJwJ6SyIQKsx+vtm7mMDYyqZhiSn ud79XBdbgYShsu0LVlvdBDMFRD0Vw7NtJ39fw1eE= Received: from NAM12-MW2-obe.outbound.protection.outlook.com (mail-mw2nam12on2075.outbound.protection.outlook.com [40.107.244.75]) by sourceware.org (Postfix) with ESMTPS id 950A5393A40A for ; Mon, 1 Mar 2021 14:47:08 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 950A5393A40A ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=T1GxpB9bqQe3AGsc6fbunNu6dJ5IqUtsXVKXKonQZH3OdLjUuom13TtMR5Dh+iQp5wcJP5tT2wgq/D6sXRgaCuKiqGvkP0tLR37KbyTbPT7Dy/FIi5XSRyoI805hRqbmPXVkKL0UzO/4jty9UWA21dcgZExu5yfKhOMGMb0CMuNhIfJRXL2BaX8aOTIgoe61/sZfBqXEugJs062R9IlA6tLMOFhecsFtM6QHOILPnOWMp0p4io3u4f88JTISC376pZJZpEDBQ3HMvcZTE7nyTZZBTZFgOO6OBXHrfMt1AJmB4/NaPQnHoahbfA2hE/9bB79/Wb3TQSSCE33wZLylnw== 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-SenderADCheck; bh=pW/7a+X/xJTRyjx6gfr3GWGjhY9LSegM0viCdUSFbKk=; b=RiRPtE0oS+bD+KqW04OA4JLhP5CQsycnkDMIknFj96Mx9ZLJag/rtjLbxSFWYk6thQ4r68vdUsHajbP1NIpyYiiayO27Byb3YikLmycPD12Xcwu9GzSrJBUEoE7nqlaMCA6ixWUtZa4LygtQxyaJaC9zjyn4fA0zJrOS+g0msO0TQ1p6d+OIzaxSLeDJYpcl1SIkho9KW/LlHk1l/r2b5UEbvEQKbmiK+rBrsKPU8SxApK+C1yt2qnuI4CaijcODMb9Ala4n4Pobpp7VVG6iLGVtTph/KPKGh3WpGbUpNyfl4bkA14UpB+Eludj9lpdnyzfnZpLCEAOoDWAGxtHOUA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none Received: from DM6PR12MB2762.namprd12.prod.outlook.com (2603:10b6:5:45::15) by DM6PR12MB3676.namprd12.prod.outlook.com (2603:10b6:5:1c7::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3890.19; Mon, 1 Mar 2021 14:46:58 +0000 Received: from DM6PR12MB2762.namprd12.prod.outlook.com ([fe80::31d8:f503:f7b2:f44]) by DM6PR12MB2762.namprd12.prod.outlook.com ([fe80::31d8:f503:f7b2:f44%3]) with mapi id 15.20.3868.033; Mon, 1 Mar 2021 14:46:58 +0000 To: gdb-patches@sourceware.org Subject: [PATCH 17/43] Add as_lval argument to expression evaluator Date: Mon, 1 Mar 2021 14:45:54 +0000 Message-Id: <20210301144620.103016-18-Zoran.Zaric@amd.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20210301144620.103016-1-Zoran.Zaric@amd.com> References: <20210301144620.103016-1-Zoran.Zaric@amd.com> Content-Type: text/plain X-Originating-IP: [2a00:23c7:5a85:6801:b4ed:fe7b:8064:d4d] X-ClientProxiedBy: AM0PR04CA0073.eurprd04.prod.outlook.com (2603:10a6:208:be::14) To DM6PR12MB2762.namprd12.prod.outlook.com (2603:10b6:5:45::15) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from localhost.localdomain (2a00:23c7:5a85:6801:b4ed:fe7b:8064:d4d) by AM0PR04CA0073.eurprd04.prod.outlook.com (2603:10a6:208:be::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3890.19 via Frontend Transport; Mon, 1 Mar 2021 14:46:57 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 1ae8eea3-73b2-4d49-f870-08d8dcc0dda7 X-MS-TrafficTypeDiagnostic: DM6PR12MB3676: X-MS-Exchange-MinimumUrlDomainAge: gnu.org#9229 X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:10000; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: jWnMvzasxSohSYjoGcDiWwyplSm+anQsGUMSTeKY0f+uJ9TrsCH/YBUInZQCnGDXMATU89cdgJxbkD47zXtV5PidqMTWy56kxjJC5uwzYxhzfKIX9HN0ZOCC704gnbVibBPF1TsFlQKsnCrHQUnopbovhiZSNWp7reObzkPK+dQF8TrvLR17EwUp+i+nSx9H3jIiw2VrQ0tah+4xxP1JS3eMbEDBR1ts2seA1H+hW+LlcmI2DkC6/rBBu+F/ABRSaSRqDLfrxDpIa/jqKqyWTgMk21QcsYUYETWtBEvHYF2k8DXEl2NVrd9Jf98TuSbXT7F2E60ulj+PS49jveWfFsZNadHkJc6CpOirtK92M91LFET7OMVyKg5y4zQFgCNHdK2phhZNooeS0EWNDNzlHtKCEc1rwuiReOOYMdrnup2I0aqcRGMZ7WrgmkLLUFGlaEOycAqb4UlSLPixSvMczkssz3lC88O65nrbZuoPoVaXy9eDGkiN+mu+tA7gJrmOjh4RSsBXo2CGtIe/XVppX5Xcwth70R2BgRVzke+IxL6EAIq0LNC8x9yoFLUKu3FCaEPCaQQxEjnfMAk0JQhTsJMsX67ipHoM1iYNJyWHJs4/qkf9hgGizOXbyxI6qZcV8HB68hzpBVq7evf5ELgYfA== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM6PR12MB2762.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(376002)(366004)(396003)(346002)(136003)(39860400002)(6666004)(16526019)(1076003)(83380400001)(2616005)(69590400012)(2906002)(186003)(36756003)(66946007)(966005)(316002)(66476007)(8936002)(52116002)(86362001)(6506007)(478600001)(5660300002)(4326008)(6486002)(8676002)(6916009)(6512007)(66556008); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData: =?us-ascii?Q?RupBS8Bk7MOyQQfj9XtbLarBEs8sb9OdVH1MrCsXpMgaFW3odbR5SKS6wpWr?= =?us-ascii?Q?zf/CvQ+0HXnPPtIX6xRFOvTrDfjeZ9BjllLzS2K4UVhrRQ1z+2ye6T4tp5Tl?= =?us-ascii?Q?rC8//EnhZf2cLBawR3XBFwM5Y3txAxQfk+h/ms49B0qImLQWUH/K6msHrf6v?= =?us-ascii?Q?5uqA2o5bWAbHhwO/WqZ0igOCCAZNjp5ytTmaOdFl/hxJl8rEyOKtr0xRUSro?= =?us-ascii?Q?Ynddf1BslbB7U5m3hVcVUKp9OlBRvqH5I5KblrM+geK7IyEiTJzqw7EZsVtY?= =?us-ascii?Q?llK4CKXiIehxBeprZtKlFrTqxJFXZPW/Ehcsj6ErLYMEdQIiWS8B8OaOZJpK?= =?us-ascii?Q?RsPzYT2tqIN+ZlVmenznBDEd/FfVAUxSBXP4vwXpmJkeOZ/fYkTnR8dIptvW?= =?us-ascii?Q?gQMnoG/xGDXYConXoYMvPUvLQudAVIlfMh8yyGhD4PyCUq1qHh3AC6fPPsOD?= =?us-ascii?Q?lEb7faEvX9HQYmYxuX48NgPrvkBPqJ3OURxL4s6CVbqhT6vMBuk4vRNisdS+?= =?us-ascii?Q?I1o3UjM2trJU8WTzUPZMUhAJ9PDGIyyPLoQ+Rr0/UlVUExkpjNLwKGgW+Wq9?= =?us-ascii?Q?Uxi1mNhAGr9vt44cLJYqDQPpYbB2P+Yq9Pnr+8lNaUnSRNWHp4dGE2+P1z7E?= =?us-ascii?Q?U/oynmMV+o47Q7zpgkQJ0BeqxynGbspqkTD4rKC0a0Fp+V2iLAUhmpnF9/PE?= =?us-ascii?Q?2+/mTwkKYKoZaxmx7wtjxFQ9UTOcjQKtjAjgSFrd794t2bUSU5XYrbAMGIOV?= =?us-ascii?Q?zjv0mlcZi/X/viBPA+HMCfBs2BXAeoPQPY0dswb/jDLdVJyaAwdZdnaKQpq7?= =?us-ascii?Q?dLtpSwKINkLciVz7Id92X38V/+5EvfT9/56GHZ3W/tISyWm1I7+dM5VibVGr?= =?us-ascii?Q?nOYAyplHXxNrIP28BsG+hsnSdMKsQlh1YCYq/IN8EAihMo+4KeOPQWV6OhWb?= =?us-ascii?Q?rnPMUXgXTwFwvk+DN8M4POat41rlpQLux5NayZOERJayiuUdrdnkm6Wl3XJN?= =?us-ascii?Q?MqRNI64BI3d1cqSTQ0PMwQ9zMSmMe/Tqd5wdbqvh14wlrLWRIsRL+Sh+htFO?= =?us-ascii?Q?nTzZAIRkYBeTRXyNcrBGND3dR62rTD4NvaWVRFmV60NU8eFE7u/88SpEIVXh?= =?us-ascii?Q?4JvRNTFFZFZOQ2iz57hWCFAgCplYcsoESWkkTU6PLLAI4uX/kqU00LOCqPQo?= =?us-ascii?Q?Q345gm7b7OPJQwXDEAxgzRNjUHc8mLtcWqXxA3oDpnIiqtLNdaOy0qiO2apZ?= =?us-ascii?Q?hqg8YeEfJteutcbVXwn3NSNV7zCv40E2IU9WbEfJKXh+ZcCstv3BA7lY/50X?= =?us-ascii?Q?e568yV9+wf8dGvXpshkW3dfXDkscL5WfY40M/t7mlrfxSaODM92oZ9QQ5ljF?= =?us-ascii?Q?S1BgG/GAIxSwIbYSSyX3FamLvcTC?= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 1ae8eea3-73b2-4d49-f870-08d8dcc0dda7 X-MS-Exchange-CrossTenant-AuthSource: DM6PR12MB2762.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 01 Mar 2021 14:46:58.6248 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: jNEw447IAK3PylSgLDUrVsJCyl4+5iE4uoAmoLO4XPpu1EvhGC0z5tnwm/h6PcAAU0n53TqqGh/MJEeQZPIcbQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR12MB3676 X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Zoran Zaric via Gdb-patches Reply-To: Zoran Zaric Errors-To: gdb-patches-bounces@sourceware.org Sender: "Gdb-patches" There are cases where the result of the expression evaluation is expected to be in a form of a value and not location description. One place that has this requirement is dwarf_entry_parameter_to_value function, but more are expected in the future. Until now, this requirement was fulfilled by extending the evaluated expression with a DW_OP_stack_value operation at the end. New implementation, introduces a new evaluation argument instead. * dwarf2/expr.c (dwarf_expr_context::fetch_result): Add as_lval argument. (dwarf_expr_context::eval_exp): Add as_lval argument. * dwarf2/expr.h (struct dwarf_expr_context): Add as_lval argument to fetch_result and eval_exp methods. * dwarf2/frame.c (execute_stack_op): Add as_lval argument. * dwarf2/loc.c (dwarf_entry_parameter_to_value): Remove DWARF expression extension. (dwarf2_evaluate_loc_desc_full): Add as_lval argument support. (dwarf2_evaluate_loc_desc): Add as_lval argument support. (dwarf2_locexpr_baton_eval): Add as_lval argument support. --- gdb/dwarf2/expr.c | 12 +++++++++--- gdb/dwarf2/expr.h | 19 ++++++++++++------- gdb/dwarf2/frame.c | 2 +- gdb/dwarf2/loc.c | 27 ++++++++++----------------- gdb/dwarf2/loc.h | 6 ++++-- 5 files changed, 36 insertions(+), 30 deletions(-) diff --git a/gdb/dwarf2/expr.c b/gdb/dwarf2/expr.c index 1645f477d74..c50bb3c8d90 100644 --- a/gdb/dwarf2/expr.c +++ b/gdb/dwarf2/expr.c @@ -899,7 +899,8 @@ dwarf_expr_context::push_dwarf_reg_entry_value struct value * dwarf_expr_context::fetch_result (struct type *type, struct type *subobj_type, - LONGEST subobj_offset) + LONGEST subobj_offset, + bool as_lval) { struct value *retval = nullptr; @@ -929,6 +930,11 @@ dwarf_expr_context::fetch_result (struct type *type, } else { + /* If AS_LVAL is false, means that the implicit conversion + from a location description to value is expected. */ + if (as_lval == false) + this->location = DWARF_VALUE_STACK; + switch (this->location) { case DWARF_VALUE_REGISTER: @@ -1053,7 +1059,7 @@ dwarf_expr_context::fetch_result (struct type *type, /* See expr.h. */ struct value * -dwarf_expr_context::evaluate (const gdb_byte *addr, size_t len, +dwarf_expr_context::evaluate (const gdb_byte *addr, size_t len, bool as_lval, struct dwarf2_per_cu_data *per_cu, struct frame_info *frame, const struct property_addr_info *addr_info, @@ -1069,7 +1075,7 @@ dwarf_expr_context::evaluate (const gdb_byte *addr, size_t len, this->ref_addr_size = per_cu->ref_addr_size (); eval (addr, len); - return fetch_result (type, subobj_type, subobj_offset); + return fetch_result (type, subobj_type, subobj_offset, as_lval); } /* Require that TYPE be an integral type; throw an exception if not. */ diff --git a/gdb/dwarf2/expr.h b/gdb/dwarf2/expr.h index d1374068732..3f519e81849 100644 --- a/gdb/dwarf2/expr.h +++ b/gdb/dwarf2/expr.h @@ -130,11 +130,13 @@ struct dwarf_expr_context void push_address (CORE_ADDR value, bool in_stack_memory); /* Evaluate the expression at ADDR (LEN bytes long) in a given PER_CU - FRAME context. Where TYPE, SUBOBJ_TYPE and SUBOBJ_OFFSET describe - expected struct value representation of the evaluation result. - The ADDR_INFO property can be specified to override the range of - memory addresses with the passed in buffer. */ - struct value *evaluate (const gdb_byte *addr, size_t len, + FRAME context. AS_LVAL defines if the returned struct value is + expected to be a value or a location description. Where TYPE, + SUBOBJ_TYPE and SUBOBJ_OFFSET describe expected struct value + representation of the evaluation result. The ADDR_INFO property + can be specified to override the range of memory addresses with + the passed in buffer. */ + struct value *evaluate (const gdb_byte *addr, size_t len, bool as_lval, struct dwarf2_per_cu_data *per_cu, struct frame_info *frame, const struct property_addr_info *addr_info = nullptr, @@ -223,10 +225,13 @@ struct dwarf_expr_context /* Fetch the result of the expression evaluation in a form of a struct value, where TYPE, SUBOBJ_TYPE and SUBOBJ_OFFSET - describe the source level representation of that result. */ + describe the source level representation of that result. + AS_LVAL defines if the fetched struct value is expected to + be a value or a location description. */ struct value *fetch_result (struct type *type, struct type *subobj_type, - LONGEST subobj_offset); + LONGEST subobj_offset, + bool as_lval); /* Return the location expression for the frame base attribute, in START and LENGTH. The result must be live until the current diff --git a/gdb/dwarf2/frame.c b/gdb/dwarf2/frame.c index 07667c3dee5..51d308fd94f 100644 --- a/gdb/dwarf2/frame.c +++ b/gdb/dwarf2/frame.c @@ -232,7 +232,7 @@ execute_stack_op (const gdb_byte *exp, ULONGEST len, int addr_size, scoped_value_mark free_values; ctx.push_address (initial, initial_in_stack_memory); - struct value *result_val = ctx.evaluate (exp, len, nullptr, this_frame); + struct value *result_val = ctx.evaluate (exp, len, true, nullptr, this_frame); if (VALUE_LVAL (result_val) == lval_memory) return value_address (result_val); diff --git a/gdb/dwarf2/loc.c b/gdb/dwarf2/loc.c index 55445021ad4..c53413a942f 100644 --- a/gdb/dwarf2/loc.c +++ b/gdb/dwarf2/loc.c @@ -50,7 +50,7 @@ static struct value *dwarf2_evaluate_loc_desc_full (struct type *type, struct frame_info *frame, const gdb_byte *data, size_t size, dwarf2_per_cu_data *per_cu, dwarf2_per_objfile *per_objfile, - struct type *subobj_type, LONGEST subobj_byte_offset); + struct type *subobj_type, LONGEST subobj_byte_offset, bool as_lval = true); /* Until these have formal names, we define these here. ref: http://gcc.gnu.org/wiki/DebugFission @@ -1183,7 +1183,6 @@ dwarf_entry_parameter_to_value (struct call_site_parameter *parameter, dwarf2_per_objfile *per_objfile) { const gdb_byte *data_src; - gdb_byte *data; size_t size; data_src = deref_size == -1 ? parameter->value : parameter->data_value; @@ -1194,15 +1193,8 @@ dwarf_entry_parameter_to_value (struct call_site_parameter *parameter, throw_error (NO_ENTRY_VALUE_ERROR, _("Cannot resolve DW_AT_call_data_value")); - /* DW_AT_call_value is a DWARF expression, not a DWARF - location. Postprocessing of DWARF_VALUE_MEMORY would lose the type from - DWARF block. */ - data = (gdb_byte *) alloca (size + 1); - memcpy (data, data_src, size); - data[size] = DW_OP_stack_value; - - return dwarf2_evaluate_loc_desc (type, caller_frame, data, size + 1, per_cu, - per_objfile); + return dwarf2_evaluate_loc_desc (type, caller_frame, data_src, size, per_cu, + per_objfile, false); } /* VALUE must be of type lval_computed with entry_data_value_funcs. Perform @@ -1428,7 +1420,8 @@ dwarf2_evaluate_loc_desc_full (struct type *type, struct frame_info *frame, dwarf2_per_cu_data *per_cu, dwarf2_per_objfile *per_objfile, struct type *subobj_type, - LONGEST subobj_byte_offset) + LONGEST subobj_byte_offset, + bool as_lval) { if (subobj_type == NULL) { @@ -1448,8 +1441,8 @@ dwarf2_evaluate_loc_desc_full (struct type *type, struct frame_info *frame, try { - retval = ctx.evaluate (data, size, per_cu, frame, nullptr, type, - subobj_type, subobj_byte_offset); + retval = ctx.evaluate (data, size, as_lval, per_cu, frame, nullptr, + type, subobj_type, subobj_byte_offset); } catch (const gdb_exception_error &ex) { @@ -1490,10 +1483,10 @@ struct value * dwarf2_evaluate_loc_desc (struct type *type, struct frame_info *frame, const gdb_byte *data, size_t size, dwarf2_per_cu_data *per_cu, - dwarf2_per_objfile *per_objfile) + dwarf2_per_objfile *per_objfile, bool as_lval) { return dwarf2_evaluate_loc_desc_full (type, frame, data, size, per_cu, - per_objfile, NULL, 0); + per_objfile, NULL, 0, as_lval); } /* Evaluates a dwarf expression and stores the result in VAL, @@ -1536,7 +1529,7 @@ dwarf2_locexpr_baton_eval (const struct dwarf2_locexpr_baton *dlbaton, try { result = ctx.evaluate (dlbaton->data, dlbaton->size, - per_cu, frame, addr_stack); + true, per_cu, frame, addr_stack); } catch (const gdb_exception_error &ex) { diff --git a/gdb/dwarf2/loc.h b/gdb/dwarf2/loc.h index 02c686e5592..c5cacce1ceb 100644 --- a/gdb/dwarf2/loc.h +++ b/gdb/dwarf2/loc.h @@ -69,14 +69,16 @@ struct call_site_parameter *dwarf_expr_reg_to_entry_parameter /* Evaluate a location description, starting at DATA and with length SIZE, to find the current location of variable of TYPE in the context - of FRAME. */ + of FRAME. AS_LVAL defines if the resulting struct value is expected to + be a value or a location description. */ struct value *dwarf2_evaluate_loc_desc (struct type *type, struct frame_info *frame, const gdb_byte *data, size_t size, dwarf2_per_cu_data *per_cu, - dwarf2_per_objfile *per_objfile); + dwarf2_per_objfile *per_objfile, + bool as_lval = true); /* A chain of addresses that might be needed to resolve a dynamic property. */ -- 2.17.1