diff mbox series

[committed] Use SCALAR_INT_TYPE_MODE in loc_list_from_tree_1

Message ID 87fuaayzj3.fsf@linaro.org
State New
Headers show
Series [committed] Use SCALAR_INT_TYPE_MODE in loc_list_from_tree_1 | expand

Commit Message

Richard Sandiford Oct. 23, 2017, 9:38 a.m. UTC
This follows on from similar changes a couple of months ago and
is needed when general modes have variable size.

Tested on aarch64-linux-gnu, x86_64-linux-gnu and powerpc64le-linux-gnu.
Applied as obvious.

Richard


2017-10-23  Richard Sandiford  <richard.sandiford@linaro.org>
	    Alan Hayward  <alan.hayward@arm.com>
	    David Sherwood  <david.sherwood@arm.com>

gcc/
	* dwarf2out.c (loc_list_from_tree_1): Use SCALAR_INT_TYPE_MODE
diff mbox series

Patch

Index: gcc/dwarf2out.c
===================================================================
--- gcc/dwarf2out.c	2017-10-19 21:19:47.742454435 +0100
+++ gcc/dwarf2out.c	2017-10-23 10:36:59.967280171 +0100
@@ -17482,7 +17482,7 @@  loc_list_from_tree_1 (tree loc, int want
 		&& (INTEGRAL_TYPE_P (TREE_TYPE (loc))
 		    || POINTER_TYPE_P (TREE_TYPE (loc)))
 		&& DECL_CONTEXT (loc) == current_function_decl
-		&& (GET_MODE_SIZE (TYPE_MODE (TREE_TYPE (loc)))
+		&& (GET_MODE_SIZE (SCALAR_INT_TYPE_MODE (TREE_TYPE (loc)))
 		    <= DWARF2_ADDR_SIZE))
 	      {
 		dw_die_ref ref = lookup_decl_die (loc);