aboutsummaryrefslogtreecommitdiff
path: root/sysdeps
diff options
context:
space:
mode:
authorWill Schmidt <will_schmidt@vnet.ibm.com>2012-04-18 15:34:23 -0500
committerRyan S. Arnold <rsa@linux.vnet.ibm.com>2012-04-18 15:34:23 -0500
commit6b652f46c3935088082bb5870b6fd9edbaa92125 (patch)
tree6813ad76813e32855c87d3ec4493cbd99058b312 /sysdeps
parentb282631e367f474bbd9e5d92e2aa54b3ce44efe8 (diff)
downloadglibc-6b652f46c3935088082bb5870b6fd9edbaa92125.zip
glibc-6b652f46c3935088082bb5870b6fd9edbaa92125.tar.gz
glibc-6b652f46c3935088082bb5870b6fd9edbaa92125.tar.bz2
Further simplify power6 wordcopy by removing switch statements.
This fix replaces switch statements that contain individual [fwd|bwd]_align_merge (<constant>) calls with a single [fwd|bwd]_align_merge (align) call.
Diffstat (limited to 'sysdeps')
-rw-r--r--sysdeps/powerpc/powerpc32/power6/wordcopy.c26
-rw-r--r--sysdeps/powerpc/powerpc64/power6/wordcopy.c50
2 files changed, 4 insertions, 72 deletions
diff --git a/sysdeps/powerpc/powerpc32/power6/wordcopy.c b/sysdeps/powerpc/powerpc32/power6/wordcopy.c
index d0df56f..698b82f 100644
--- a/sysdeps/powerpc/powerpc32/power6/wordcopy.c
+++ b/sysdeps/powerpc/powerpc32/power6/wordcopy.c
@@ -115,18 +115,7 @@ _wordcopy_fwd_dest_aligned (dstp, srcp, len)
len -= 1;
}
- switch (align)
- {
- case 1:
- fwd_align_merge (1);
- break;
- case 2:
- fwd_align_merge (2);
- break;
- case 3:
- fwd_align_merge (3);
- break;
- }
+ fwd_align_merge (align);
}
@@ -224,16 +213,5 @@ _wordcopy_bwd_dest_aligned (dstp, srcp, len)
len -= 1;
}
- switch (align)
- {
- case 1:
- bwd_align_merge (1);
- break;
- case 2:
- bwd_align_merge (2);
- break;
- case 3:
- bwd_align_merge (3);
- break;
- }
+ bwd_align_merge (align);
}
diff --git a/sysdeps/powerpc/powerpc64/power6/wordcopy.c b/sysdeps/powerpc/powerpc64/power6/wordcopy.c
index b18b97f..4c72404 100644
--- a/sysdeps/powerpc/powerpc64/power6/wordcopy.c
+++ b/sysdeps/powerpc/powerpc64/power6/wordcopy.c
@@ -115,30 +115,7 @@ _wordcopy_fwd_dest_aligned (dstp, srcp, len)
len -= 1;
}
- switch (align)
- {
- case 1:
- fwd_align_merge (1);
- break;
- case 2:
- fwd_align_merge (2);
- break;
- case 3:
- fwd_align_merge (3);
- break;
- case 4:
- fwd_align_merge (4);
- break;
- case 5:
- fwd_align_merge (5);
- break;
- case 6:
- fwd_align_merge (6);
- break;
- case 7:
- fwd_align_merge (7);
- break;
- }
+ fwd_align_merge (align);
}
@@ -236,28 +213,5 @@ _wordcopy_bwd_dest_aligned (dstp, srcp, len)
len -= 1;
}
- switch (align)
- {
- case 1:
- bwd_align_merge (1);
- break;
- case 2:
- bwd_align_merge (2);
- break;
- case 3:
- bwd_align_merge (3);
- break;
- case 4:
- bwd_align_merge (4);
- break;
- case 5:
- bwd_align_merge (5);
- break;
- case 6:
- bwd_align_merge (6);
- break;
- case 7:
- bwd_align_merge (7);
- break;
- }
+ bwd_align_merge (align);
}