Message ID | 20220902210533.373663-1-vineetg@rivosinc.com |
---|---|
State | New |
Headers | show |
Series | [v3] RISC-V: remove deprecate pic code model macro | expand |
On 9/2/22 14:05, Vineet Gupta wrote: > Came across this deprecated symbol when looking around for > -mexplicit-relocs handling in code > > Signed-off-by: Vineet Gupta <vineetg@rivosinc.com> No rush but looks like this got lost in the bigger thread about LOAD_ADDRESS_MACRO. Thx, -Vineet > --- > gcc/config/riscv/riscv-c.cc | 5 ----- > gcc/testsuite/gcc.target/riscv/predef-1.c | 3 --- > gcc/testsuite/gcc.target/riscv/predef-2.c | 3 --- > gcc/testsuite/gcc.target/riscv/predef-3.c | 3 --- > gcc/testsuite/gcc.target/riscv/predef-4.c | 3 --- > gcc/testsuite/gcc.target/riscv/predef-5.c | 3 --- > gcc/testsuite/gcc.target/riscv/predef-6.c | 3 --- > gcc/testsuite/gcc.target/riscv/predef-7.c | 3 --- > gcc/testsuite/gcc.target/riscv/predef-8.c | 3 --- > 9 files changed, 29 deletions(-) > > diff --git a/gcc/config/riscv/riscv-c.cc b/gcc/config/riscv/riscv-c.cc > index eb7ef09297e9..8d55ad598a9c 100644 > --- a/gcc/config/riscv/riscv-c.cc > +++ b/gcc/config/riscv/riscv-c.cc > @@ -93,11 +93,6 @@ riscv_cpu_cpp_builtins (cpp_reader *pfile) > break; > > case CM_PIC: > - /* __riscv_cmodel_pic is deprecated, and will removed in next GCC release. > - see https://github.com/riscv/riscv-c-api-doc/pull/11 */ > - builtin_define ("__riscv_cmodel_pic"); > - /* FALLTHROUGH. */ > - > case CM_MEDANY: > builtin_define ("__riscv_cmodel_medany"); > break; > diff --git a/gcc/testsuite/gcc.target/riscv/predef-1.c b/gcc/testsuite/gcc.target/riscv/predef-1.c > index 2e57ce6b3954..9dddc1849635 100644 > --- a/gcc/testsuite/gcc.target/riscv/predef-1.c > +++ b/gcc/testsuite/gcc.target/riscv/predef-1.c > @@ -57,9 +57,6 @@ int main () { > #endif > #if defined(__riscv_cmodel_medany) > #error "__riscv_cmodel_medlow" > -#endif > -#if defined(__riscv_cmodel_pic) > -#error "__riscv_cmodel_medlow" > #endif > > return 0; > diff --git a/gcc/testsuite/gcc.target/riscv/predef-2.c b/gcc/testsuite/gcc.target/riscv/predef-2.c > index c85b3c9fd32a..755fe4ef7d8a 100644 > --- a/gcc/testsuite/gcc.target/riscv/predef-2.c > +++ b/gcc/testsuite/gcc.target/riscv/predef-2.c > @@ -57,9 +57,6 @@ int main () { > #endif > #if !defined(__riscv_cmodel_medany) > #error "__riscv_cmodel_medlow" > -#endif > -#if defined(__riscv_cmodel_pic) > -#error "__riscv_cmodel_medlow" > #endif > > return 0; > diff --git a/gcc/testsuite/gcc.target/riscv/predef-3.c b/gcc/testsuite/gcc.target/riscv/predef-3.c > index 82a89d415809..513645351c09 100644 > --- a/gcc/testsuite/gcc.target/riscv/predef-3.c > +++ b/gcc/testsuite/gcc.target/riscv/predef-3.c > @@ -57,9 +57,6 @@ int main () { > #endif > #if !defined(__riscv_cmodel_medany) > #error "__riscv_cmodel_medany" > -#endif > -#if !defined(__riscv_cmodel_pic) > -#error "__riscv_cmodel_pic" > #endif > > return 0; > diff --git a/gcc/testsuite/gcc.target/riscv/predef-4.c b/gcc/testsuite/gcc.target/riscv/predef-4.c > index 5868d39eb67a..76b6feec6b6f 100644 > --- a/gcc/testsuite/gcc.target/riscv/predef-4.c > +++ b/gcc/testsuite/gcc.target/riscv/predef-4.c > @@ -57,9 +57,6 @@ int main () { > #endif > #if defined(__riscv_cmodel_medany) > #error "__riscv_cmodel_medlow" > -#endif > -#if defined(__riscv_cmodel_pic) > -#error "__riscv_cmodel_medlow" > #endif > > return 0; > diff --git a/gcc/testsuite/gcc.target/riscv/predef-5.c b/gcc/testsuite/gcc.target/riscv/predef-5.c > index 4b2bd3835061..54a51508afbd 100644 > --- a/gcc/testsuite/gcc.target/riscv/predef-5.c > +++ b/gcc/testsuite/gcc.target/riscv/predef-5.c > @@ -57,9 +57,6 @@ int main () { > #endif > #if !defined(__riscv_cmodel_medany) > #error "__riscv_cmodel_medlow" > -#endif > -#if defined(__riscv_cmodel_pic) > -#error "__riscv_cmodel_medlow" > #endif > > return 0; > diff --git a/gcc/testsuite/gcc.target/riscv/predef-6.c b/gcc/testsuite/gcc.target/riscv/predef-6.c > index 8e5ea366bd5e..f61709f7bf32 100644 > --- a/gcc/testsuite/gcc.target/riscv/predef-6.c > +++ b/gcc/testsuite/gcc.target/riscv/predef-6.c > @@ -57,9 +57,6 @@ int main () { > #endif > #if !defined(__riscv_cmodel_medany) > #error "__riscv_cmodel_medany" > -#endif > -#if !defined(__riscv_cmodel_pic) > -#error "__riscv_cmodel_medpic" > #endif > > return 0; > diff --git a/gcc/testsuite/gcc.target/riscv/predef-7.c b/gcc/testsuite/gcc.target/riscv/predef-7.c > index 0bde299aef1a..41217554c4db 100644 > --- a/gcc/testsuite/gcc.target/riscv/predef-7.c > +++ b/gcc/testsuite/gcc.target/riscv/predef-7.c > @@ -57,9 +57,6 @@ int main () { > #endif > #if defined(__riscv_cmodel_medany) > #error "__riscv_cmodel_medlow" > -#endif > -#if defined(__riscv_cmodel_pic) > -#error "__riscv_cmodel_medlow" > #endif > > return 0; > diff --git a/gcc/testsuite/gcc.target/riscv/predef-8.c b/gcc/testsuite/gcc.target/riscv/predef-8.c > index 18aa591a6039..982056a53438 100644 > --- a/gcc/testsuite/gcc.target/riscv/predef-8.c > +++ b/gcc/testsuite/gcc.target/riscv/predef-8.c > @@ -57,9 +57,6 @@ int main () { > #endif > #if !defined(__riscv_cmodel_medany) > #error "__riscv_cmodel_medlow" > -#endif > -#if defined(__riscv_cmodel_pic) > -#error "__riscv_cmodel_medlow" > #endif > > return 0;
Committed, and added ChangeLog, remember to add that next time :) On Sat, Sep 24, 2022 at 2:08 AM Vineet Gupta <vineetg@rivosinc.com> wrote: > > On 9/2/22 14:05, Vineet Gupta wrote: > > Came across this deprecated symbol when looking around for > > -mexplicit-relocs handling in code > > > > Signed-off-by: Vineet Gupta <vineetg@rivosinc.com> > > No rush but looks like this got lost in the bigger thread about > LOAD_ADDRESS_MACRO. > > Thx, > -Vineet > > > --- > > gcc/config/riscv/riscv-c.cc | 5 ----- > > gcc/testsuite/gcc.target/riscv/predef-1.c | 3 --- > > gcc/testsuite/gcc.target/riscv/predef-2.c | 3 --- > > gcc/testsuite/gcc.target/riscv/predef-3.c | 3 --- > > gcc/testsuite/gcc.target/riscv/predef-4.c | 3 --- > > gcc/testsuite/gcc.target/riscv/predef-5.c | 3 --- > > gcc/testsuite/gcc.target/riscv/predef-6.c | 3 --- > > gcc/testsuite/gcc.target/riscv/predef-7.c | 3 --- > > gcc/testsuite/gcc.target/riscv/predef-8.c | 3 --- > > 9 files changed, 29 deletions(-) > > > > diff --git a/gcc/config/riscv/riscv-c.cc b/gcc/config/riscv/riscv-c.cc > > index eb7ef09297e9..8d55ad598a9c 100644 > > --- a/gcc/config/riscv/riscv-c.cc > > +++ b/gcc/config/riscv/riscv-c.cc > > @@ -93,11 +93,6 @@ riscv_cpu_cpp_builtins (cpp_reader *pfile) > > break; > > > > case CM_PIC: > > - /* __riscv_cmodel_pic is deprecated, and will removed in next GCC release. > > - see https://github.com/riscv/riscv-c-api-doc/pull/11 */ > > - builtin_define ("__riscv_cmodel_pic"); > > - /* FALLTHROUGH. */ > > - > > case CM_MEDANY: > > builtin_define ("__riscv_cmodel_medany"); > > break; > > diff --git a/gcc/testsuite/gcc.target/riscv/predef-1.c b/gcc/testsuite/gcc.target/riscv/predef-1.c > > index 2e57ce6b3954..9dddc1849635 100644 > > --- a/gcc/testsuite/gcc.target/riscv/predef-1.c > > +++ b/gcc/testsuite/gcc.target/riscv/predef-1.c > > @@ -57,9 +57,6 @@ int main () { > > #endif > > #if defined(__riscv_cmodel_medany) > > #error "__riscv_cmodel_medlow" > > -#endif > > -#if defined(__riscv_cmodel_pic) > > -#error "__riscv_cmodel_medlow" > > #endif > > > > return 0; > > diff --git a/gcc/testsuite/gcc.target/riscv/predef-2.c b/gcc/testsuite/gcc.target/riscv/predef-2.c > > index c85b3c9fd32a..755fe4ef7d8a 100644 > > --- a/gcc/testsuite/gcc.target/riscv/predef-2.c > > +++ b/gcc/testsuite/gcc.target/riscv/predef-2.c > > @@ -57,9 +57,6 @@ int main () { > > #endif > > #if !defined(__riscv_cmodel_medany) > > #error "__riscv_cmodel_medlow" > > -#endif > > -#if defined(__riscv_cmodel_pic) > > -#error "__riscv_cmodel_medlow" > > #endif > > > > return 0; > > diff --git a/gcc/testsuite/gcc.target/riscv/predef-3.c b/gcc/testsuite/gcc.target/riscv/predef-3.c > > index 82a89d415809..513645351c09 100644 > > --- a/gcc/testsuite/gcc.target/riscv/predef-3.c > > +++ b/gcc/testsuite/gcc.target/riscv/predef-3.c > > @@ -57,9 +57,6 @@ int main () { > > #endif > > #if !defined(__riscv_cmodel_medany) > > #error "__riscv_cmodel_medany" > > -#endif > > -#if !defined(__riscv_cmodel_pic) > > -#error "__riscv_cmodel_pic" > > #endif > > > > return 0; > > diff --git a/gcc/testsuite/gcc.target/riscv/predef-4.c b/gcc/testsuite/gcc.target/riscv/predef-4.c > > index 5868d39eb67a..76b6feec6b6f 100644 > > --- a/gcc/testsuite/gcc.target/riscv/predef-4.c > > +++ b/gcc/testsuite/gcc.target/riscv/predef-4.c > > @@ -57,9 +57,6 @@ int main () { > > #endif > > #if defined(__riscv_cmodel_medany) > > #error "__riscv_cmodel_medlow" > > -#endif > > -#if defined(__riscv_cmodel_pic) > > -#error "__riscv_cmodel_medlow" > > #endif > > > > return 0; > > diff --git a/gcc/testsuite/gcc.target/riscv/predef-5.c b/gcc/testsuite/gcc.target/riscv/predef-5.c > > index 4b2bd3835061..54a51508afbd 100644 > > --- a/gcc/testsuite/gcc.target/riscv/predef-5.c > > +++ b/gcc/testsuite/gcc.target/riscv/predef-5.c > > @@ -57,9 +57,6 @@ int main () { > > #endif > > #if !defined(__riscv_cmodel_medany) > > #error "__riscv_cmodel_medlow" > > -#endif > > -#if defined(__riscv_cmodel_pic) > > -#error "__riscv_cmodel_medlow" > > #endif > > > > return 0; > > diff --git a/gcc/testsuite/gcc.target/riscv/predef-6.c b/gcc/testsuite/gcc.target/riscv/predef-6.c > > index 8e5ea366bd5e..f61709f7bf32 100644 > > --- a/gcc/testsuite/gcc.target/riscv/predef-6.c > > +++ b/gcc/testsuite/gcc.target/riscv/predef-6.c > > @@ -57,9 +57,6 @@ int main () { > > #endif > > #if !defined(__riscv_cmodel_medany) > > #error "__riscv_cmodel_medany" > > -#endif > > -#if !defined(__riscv_cmodel_pic) > > -#error "__riscv_cmodel_medpic" > > #endif > > > > return 0; > > diff --git a/gcc/testsuite/gcc.target/riscv/predef-7.c b/gcc/testsuite/gcc.target/riscv/predef-7.c > > index 0bde299aef1a..41217554c4db 100644 > > --- a/gcc/testsuite/gcc.target/riscv/predef-7.c > > +++ b/gcc/testsuite/gcc.target/riscv/predef-7.c > > @@ -57,9 +57,6 @@ int main () { > > #endif > > #if defined(__riscv_cmodel_medany) > > #error "__riscv_cmodel_medlow" > > -#endif > > -#if defined(__riscv_cmodel_pic) > > -#error "__riscv_cmodel_medlow" > > #endif > > > > return 0; > > diff --git a/gcc/testsuite/gcc.target/riscv/predef-8.c b/gcc/testsuite/gcc.target/riscv/predef-8.c > > index 18aa591a6039..982056a53438 100644 > > --- a/gcc/testsuite/gcc.target/riscv/predef-8.c > > +++ b/gcc/testsuite/gcc.target/riscv/predef-8.c > > @@ -57,9 +57,6 @@ int main () { > > #endif > > #if !defined(__riscv_cmodel_medany) > > #error "__riscv_cmodel_medlow" > > -#endif > > -#if defined(__riscv_cmodel_pic) > > -#error "__riscv_cmodel_medlow" > > #endif > > > > return 0; >
On 10/4/22 19:24, Kito Cheng wrote:
> Committed, and added ChangeLog, remember to add that next time:)
Oops sorry, I will.
Thx,
-Vineet
diff --git a/gcc/config/riscv/riscv-c.cc b/gcc/config/riscv/riscv-c.cc index eb7ef09297e9..8d55ad598a9c 100644 --- a/gcc/config/riscv/riscv-c.cc +++ b/gcc/config/riscv/riscv-c.cc @@ -93,11 +93,6 @@ riscv_cpu_cpp_builtins (cpp_reader *pfile) break; case CM_PIC: - /* __riscv_cmodel_pic is deprecated, and will removed in next GCC release. - see https://github.com/riscv/riscv-c-api-doc/pull/11 */ - builtin_define ("__riscv_cmodel_pic"); - /* FALLTHROUGH. */ - case CM_MEDANY: builtin_define ("__riscv_cmodel_medany"); break; diff --git a/gcc/testsuite/gcc.target/riscv/predef-1.c b/gcc/testsuite/gcc.target/riscv/predef-1.c index 2e57ce6b3954..9dddc1849635 100644 --- a/gcc/testsuite/gcc.target/riscv/predef-1.c +++ b/gcc/testsuite/gcc.target/riscv/predef-1.c @@ -57,9 +57,6 @@ int main () { #endif #if defined(__riscv_cmodel_medany) #error "__riscv_cmodel_medlow" -#endif -#if defined(__riscv_cmodel_pic) -#error "__riscv_cmodel_medlow" #endif return 0; diff --git a/gcc/testsuite/gcc.target/riscv/predef-2.c b/gcc/testsuite/gcc.target/riscv/predef-2.c index c85b3c9fd32a..755fe4ef7d8a 100644 --- a/gcc/testsuite/gcc.target/riscv/predef-2.c +++ b/gcc/testsuite/gcc.target/riscv/predef-2.c @@ -57,9 +57,6 @@ int main () { #endif #if !defined(__riscv_cmodel_medany) #error "__riscv_cmodel_medlow" -#endif -#if defined(__riscv_cmodel_pic) -#error "__riscv_cmodel_medlow" #endif return 0; diff --git a/gcc/testsuite/gcc.target/riscv/predef-3.c b/gcc/testsuite/gcc.target/riscv/predef-3.c index 82a89d415809..513645351c09 100644 --- a/gcc/testsuite/gcc.target/riscv/predef-3.c +++ b/gcc/testsuite/gcc.target/riscv/predef-3.c @@ -57,9 +57,6 @@ int main () { #endif #if !defined(__riscv_cmodel_medany) #error "__riscv_cmodel_medany" -#endif -#if !defined(__riscv_cmodel_pic) -#error "__riscv_cmodel_pic" #endif return 0; diff --git a/gcc/testsuite/gcc.target/riscv/predef-4.c b/gcc/testsuite/gcc.target/riscv/predef-4.c index 5868d39eb67a..76b6feec6b6f 100644 --- a/gcc/testsuite/gcc.target/riscv/predef-4.c +++ b/gcc/testsuite/gcc.target/riscv/predef-4.c @@ -57,9 +57,6 @@ int main () { #endif #if defined(__riscv_cmodel_medany) #error "__riscv_cmodel_medlow" -#endif -#if defined(__riscv_cmodel_pic) -#error "__riscv_cmodel_medlow" #endif return 0; diff --git a/gcc/testsuite/gcc.target/riscv/predef-5.c b/gcc/testsuite/gcc.target/riscv/predef-5.c index 4b2bd3835061..54a51508afbd 100644 --- a/gcc/testsuite/gcc.target/riscv/predef-5.c +++ b/gcc/testsuite/gcc.target/riscv/predef-5.c @@ -57,9 +57,6 @@ int main () { #endif #if !defined(__riscv_cmodel_medany) #error "__riscv_cmodel_medlow" -#endif -#if defined(__riscv_cmodel_pic) -#error "__riscv_cmodel_medlow" #endif return 0; diff --git a/gcc/testsuite/gcc.target/riscv/predef-6.c b/gcc/testsuite/gcc.target/riscv/predef-6.c index 8e5ea366bd5e..f61709f7bf32 100644 --- a/gcc/testsuite/gcc.target/riscv/predef-6.c +++ b/gcc/testsuite/gcc.target/riscv/predef-6.c @@ -57,9 +57,6 @@ int main () { #endif #if !defined(__riscv_cmodel_medany) #error "__riscv_cmodel_medany" -#endif -#if !defined(__riscv_cmodel_pic) -#error "__riscv_cmodel_medpic" #endif return 0; diff --git a/gcc/testsuite/gcc.target/riscv/predef-7.c b/gcc/testsuite/gcc.target/riscv/predef-7.c index 0bde299aef1a..41217554c4db 100644 --- a/gcc/testsuite/gcc.target/riscv/predef-7.c +++ b/gcc/testsuite/gcc.target/riscv/predef-7.c @@ -57,9 +57,6 @@ int main () { #endif #if defined(__riscv_cmodel_medany) #error "__riscv_cmodel_medlow" -#endif -#if defined(__riscv_cmodel_pic) -#error "__riscv_cmodel_medlow" #endif return 0; diff --git a/gcc/testsuite/gcc.target/riscv/predef-8.c b/gcc/testsuite/gcc.target/riscv/predef-8.c index 18aa591a6039..982056a53438 100644 --- a/gcc/testsuite/gcc.target/riscv/predef-8.c +++ b/gcc/testsuite/gcc.target/riscv/predef-8.c @@ -57,9 +57,6 @@ int main () { #endif #if !defined(__riscv_cmodel_medany) #error "__riscv_cmodel_medlow" -#endif -#if defined(__riscv_cmodel_pic) -#error "__riscv_cmodel_medlow" #endif return 0;
Came across this deprecated symbol when looking around for -mexplicit-relocs handling in code Signed-off-by: Vineet Gupta <vineetg@rivosinc.com> --- gcc/config/riscv/riscv-c.cc | 5 ----- gcc/testsuite/gcc.target/riscv/predef-1.c | 3 --- gcc/testsuite/gcc.target/riscv/predef-2.c | 3 --- gcc/testsuite/gcc.target/riscv/predef-3.c | 3 --- gcc/testsuite/gcc.target/riscv/predef-4.c | 3 --- gcc/testsuite/gcc.target/riscv/predef-5.c | 3 --- gcc/testsuite/gcc.target/riscv/predef-6.c | 3 --- gcc/testsuite/gcc.target/riscv/predef-7.c | 3 --- gcc/testsuite/gcc.target/riscv/predef-8.c | 3 --- 9 files changed, 29 deletions(-)