diff options
author | Eric Botcazou <ebotcazou@gcc.gnu.org> | 2020-05-09 21:37:13 +0200 |
---|---|---|
committer | Eric Botcazou <ebotcazou@gcc.gnu.org> | 2020-05-09 22:14:04 +0200 |
commit | 65ba91b79e1664ba7e7f60f68e4cb956453b692e (patch) | |
tree | 65d9b2f0e7fdd202b43b2904e14a15d159eb9794 /gcc/ada/gcc-interface/utils2.c | |
parent | 8415ced06ed9690dfbce8b8b5f2f4f98f15598b6 (diff) | |
download | gcc-65ba91b79e1664ba7e7f60f68e4cb956453b692e.zip gcc-65ba91b79e1664ba7e7f60f68e4cb956453b692e.tar.gz gcc-65ba91b79e1664ba7e7f60f68e4cb956453b692e.tar.bz2 |
Remove last use of expr_align
It was in the ada/gcc-interface repository and is outdated.
* tree.h (expr_align): Delete.
* tree.c (expr_align): Likewise.
ada/
* gcc-interface/utils2.c: Include builtins.h.
(known_alignment) <ADDR_EXPR>: Use DECL_ALIGN for DECL_P operands
and get_object_alignment for the rest.
Diffstat (limited to 'gcc/ada/gcc-interface/utils2.c')
-rw-r--r-- | gcc/ada/gcc-interface/utils2.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/gcc/ada/gcc-interface/utils2.c b/gcc/ada/gcc-interface/utils2.c index 6ff1372..30d08f5 100644 --- a/gcc/ada/gcc-interface/utils2.c +++ b/gcc/ada/gcc-interface/utils2.c @@ -32,6 +32,7 @@ #include "alias.h" #include "tree.h" #include "inchash.h" +#include "builtins.h" #include "fold-const.h" #include "stor-layout.h" #include "stringpool.h" @@ -167,7 +168,10 @@ known_alignment (tree exp) break; case ADDR_EXPR: - this_alignment = expr_align (TREE_OPERAND (exp, 0)); + if (DECL_P (TREE_OPERAND (exp, 0))) + this_alignment = DECL_ALIGN (TREE_OPERAND (exp, 0)); + else + this_alignment = get_object_alignment (TREE_OPERAND (exp, 0)); break; case CALL_EXPR: |