diff options
author | mengqinggang <mengqinggang@loongson.cn> | 2024-09-02 09:51:04 +0800 |
---|---|---|
committer | caiyinyu <caiyinyu@loongson.cn> | 2024-09-06 15:46:13 +0800 |
commit | 6252c59f15b373b51e11b787b7b7f33974cd0a27 (patch) | |
tree | e2814c104d4fe5c774d9d5ed6c443c16f3fb19f6 | |
parent | 1b171c942ea066c08a1e5aefb977e35da08ed291 (diff) | |
download | glibc-6252c59f15b373b51e11b787b7b7f33974cd0a27.tar.gz glibc-6252c59f15b373b51e11b787b7b7f33974cd0a27.tar.xz glibc-6252c59f15b373b51e11b787b7b7f33974cd0a27.zip |
LoongArch: Fix macro redefined warning in tls-desc.S
Undef macro to avoid redefined warning.
-rw-r--r-- | sysdeps/loongarch/dl-tlsdesc-dynamic.h | 9 | ||||
-rw-r--r-- | sysdeps/loongarch/dl-tlsdesc.S | 12 |
2 files changed, 15 insertions, 6 deletions
diff --git a/sysdeps/loongarch/dl-tlsdesc-dynamic.h b/sysdeps/loongarch/dl-tlsdesc-dynamic.h index d10f4a8800..3daf991001 100644 --- a/sysdeps/loongarch/dl-tlsdesc-dynamic.h +++ b/sysdeps/loongarch/dl-tlsdesc-dynamic.h @@ -19,9 +19,6 @@ <https://www.gnu.org/licenses/>. */ #define FRAME_SIZE (-((-14 * SZREG) & ALMASK)) -#define FRAME_SIZE_LSX (-((-32 * SZVREG) & ALMASK)) -#define FRAME_SIZE_LASX (-((-32 * SZXREG) & ALMASK)) -#define FRAME_SIZE_FLOAT (-((-24 * SZFREG) & ALMASK)) /* Handler for dynamic TLS symbols. Prototype: @@ -155,7 +152,7 @@ Hign address dynamic_block1 <----- dtv5 */ #ifdef USE_LASX #define V_REG_S xvst #define V_REG_L xvld - #define V_SPACE FRAME_SIZE_LASX + #define V_SPACE (-((-32 * SZXREG) & ALMASK)) /* Space for LASX registers. */ #define V_REG(n) $xr##n #define V_REGS 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16, \ 17,18,19,20,21,22,23,24,25,26,27,28,29,30,31 @@ -163,7 +160,7 @@ Hign address dynamic_block1 <----- dtv5 */ #elif defined USE_LSX #define V_REG_S vst #define V_REG_L vld - #define V_SPACE FRAME_SIZE_LSX + #define V_SPACE (-((-32 * SZVREG) & ALMASK)) /* Space for LSX registers. */ #define V_REG(n) $vr##n #define V_REGS 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16, \ 17,18,19,20,21,22,23,24,25,26,27,28,29,30,31 @@ -171,7 +168,7 @@ Hign address dynamic_block1 <----- dtv5 */ #else #define V_REG_S fst.d #define V_REG_L fld.d - #define V_SPACE FRAME_SIZE_FLOAT + #define V_SPACE (-((-24 * SZFREG) & ALMASK)) /* Space for FLOAT registers. */ #define V_REG(n) $f##n #define V_REGS 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23 #define V_REGSZ SZFREG diff --git a/sysdeps/loongarch/dl-tlsdesc.S b/sysdeps/loongarch/dl-tlsdesc.S index b6cfd6121d..be76c07cce 100644 --- a/sysdeps/loongarch/dl-tlsdesc.S +++ b/sysdeps/loongarch/dl-tlsdesc.S @@ -69,6 +69,12 @@ _dl_tlsdesc_undefweak: #define Lslow Lslow_lasx #include "dl-tlsdesc-dynamic.h" #undef FRAME_SIZE +#undef V_REG_S +#undef V_REG_L +#undef V_SPACE +#undef V_REG +#undef V_REGS +#undef V_REGSZ #undef USE_LASX #undef _dl_tlsdesc_dynamic #undef Lret @@ -80,6 +86,12 @@ _dl_tlsdesc_undefweak: #define Lslow Lslow_lsx #include "dl-tlsdesc-dynamic.h" #undef FRAME_SIZE +#undef V_REG_S +#undef V_REG_L +#undef V_SPACE +#undef V_REG +#undef V_REGS +#undef V_REGSZ #undef USE_LSX #undef _dl_tlsdesc_dynamic #undef Lret |