summaryrefslogtreecommitdiff
path: root/libavutil/arm
diff options
context:
space:
mode:
authorMartin Storsjö <martin@martin.st>2016-11-10 13:23:38 +0200
committerMartin Storsjö <martin@martin.st>2016-11-10 14:01:04 +0200
commit824e8c284054f323f854892d1b4739239ed1fdc7 (patch)
tree78bc6aa2fbcc06d661cd70137660331d7a43c816 /libavutil/arm
parent905cdcaa9d081d3d945ce555b27b43a75c3af57b (diff)
downloadffmpeg-824e8c284054f323f854892d1b4739239ed1fdc7.tar.gz
arm: Clear the gp register alias at the end of functions
We reset .Lpic_gp to zero at the start of each function, which means that the logic within movrelx for clearing gp when necessary will be missed. This fixes using movrelx in different functions with a different helper register. Signed-off-by: Martin Storsjö <martin@martin.st>
Diffstat (limited to 'libavutil/arm')
-rw-r--r--libavutil/arm/asm.S3
1 files changed, 3 insertions, 0 deletions
diff --git a/libavutil/arm/asm.S b/libavutil/arm/asm.S
index 1a048b56fb..4ac0ea2e4f 100644
--- a/libavutil/arm/asm.S
+++ b/libavutil/arm/asm.S
@@ -83,6 +83,9 @@ ELF .section .note.GNU-stack,"",%progbits @ Mark stack as non-executable
put_pic %(.Lpic_idx - 1)
.noaltmacro
.endif
+ .if .Lpic_gp
+ .unreq gp
+ .endif
ELF .size \name, . - \name
FUNC .endfunc
.purgem endfunc