diff options
author | rth <rth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2004-07-14 21:19:39 +0000 |
---|---|---|
committer | rth <rth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2004-07-14 21:19:39 +0000 |
commit | 2cd7bb8449273be0565592f53a711b8196bb0bca (patch) | |
tree | e0d82178249e0ae888344ddf64b600801b7b9a7b /gcc/config/c4x | |
parent | 48da0c25d14deee27fd788057af292249b5cde3d (diff) | |
download | gcc-2cd7bb8449273be0565592f53a711b8196bb0bca.tar.gz |
* config/alpha/alpha.c (alpha_gimplify_va_arg_1): Move indirect ...
(alpha_gimplify_va_arg): ... handling here. Use pass_by_reference.
* config/c4x/c4x.c (c4x_gimplify_va_arg_expr): Use pass_by_reference.
* config/i386/i386.c (ix86_gimplify_va_arg): Likewise.
* config/i860/i860.c (i860_gimplify_va_arg_expr): Likewise.
* config/ia64/ia64.c (ia64_gimplify_va_arg): Likewise.
* config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Likewise.
* config/sh/sh.c (sh_gimplify_va_arg_expr): Likewise.
* config/xtensa/xtensa.c (xtensa_gimplify_va_arg_expr): Likewise.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@84713 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/config/c4x')
-rw-r--r-- | gcc/config/c4x/c4x.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/gcc/config/c4x/c4x.c b/gcc/config/c4x/c4x.c index f1863cb68fb..4e6dd8f5484 100644 --- a/gcc/config/c4x/c4x.c +++ b/gcc/config/c4x/c4x.c @@ -733,12 +733,20 @@ c4x_gimplify_va_arg_expr (tree valist, tree type, tree *post_p ATTRIBUTE_UNUSED) { tree t; + bool indirect; + + indirect = pass_by_reference (NULL, TYPE_MODE (type), type, false); + if (indirect) + type = build_pointer_type (type); t = build (PREDECREMENT_EXPR, TREE_TYPE (valist), valist, build_int_2 (int_size_in_bytes (type), 0)); t = fold_convert (build_pointer_type (type), t); t = build_fold_indirect_ref (t); + if (indirect) + t = build_fold_indirect_ref (t); + return t; } |