diff mbox

Build crt*vr.S with AltiVec enabled

Message ID e35c2d7f05eb74e8062fce1ef766abc5024cb774.1489170054.git.segher@kernel.crashing.org
State New
Headers show

Commit Message

Segher Boessenkool March 10, 2017, 7:25 p.m. UTC
These files won't build on targets that do not have AltiVec enabled,
breaking the build, unless we tell GAS that Altivec insns are fine.
The alternative is to not build these files in that case, which is much
more complicated.

Tested on powerpc64-linux {-m64,-m32}, powerpc64le-linux, and on
powerpc-linux-paired.  Committing to trunk.


Segher


2017-03-10  Segher Boessenkool  <segher@kernel.crashing.org>

libgcc/
	* config/rs6000/crtrestvr.s: Use .machine altivec.
	* config/rs6000/crtsavevr.s: Ditto.

---
 libgcc/config/rs6000/crtrestvr.S | 1 +
 libgcc/config/rs6000/crtsavevr.S | 1 +
 2 files changed, 2 insertions(+)
diff mbox

Patch

diff --git a/libgcc/config/rs6000/crtrestvr.S b/libgcc/config/rs6000/crtrestvr.S
index 592a2b4..a44ab89 100644
--- a/libgcc/config/rs6000/crtrestvr.S
+++ b/libgcc/config/rs6000/crtrestvr.S
@@ -31,6 +31,7 @@ 
 
 /* Called with r0 pointing just beyond the end of the vector save area.  */
 
+	.machine altivec
 	.section ".text"
 CFI_STARTPROC
 HIDDEN_FUNC(_restvr_20)
diff --git a/libgcc/config/rs6000/crtsavevr.S b/libgcc/config/rs6000/crtsavevr.S
index 2fd54c4..bc02019 100644
--- a/libgcc/config/rs6000/crtsavevr.S
+++ b/libgcc/config/rs6000/crtsavevr.S
@@ -31,6 +31,7 @@ 
 
 /* Called with r0 pointing just beyond the end of the vector save area.  */
 
+	.machine altivec
 	.section ".text"
 CFI_STARTPROC
 HIDDEN_FUNC(_savevr_20)