summaryrefslogtreecommitdiff
path: root/gcc/config/rs6000/rs6000.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/config/rs6000/rs6000.c')
-rw-r--r--gcc/config/rs6000/rs6000.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c
index 90be03e1296..97a3b81b08d 100644
--- a/gcc/config/rs6000/rs6000.c
+++ b/gcc/config/rs6000/rs6000.c
@@ -3543,9 +3543,16 @@ rs6000_builtin_vectorization_cost (enum vect_cost_for_stmt type_of_cost,
return 1;
case vec_perm:
- if (!TARGET_VSX)
+ if (TARGET_VSX)
+ return 4;
+ else
return 1;
- return 2;
+
+ case vec_promote_demote:
+ if (TARGET_VSX)
+ return 5;
+ else
+ return 1;
case cond_branch_taken:
return 3;