C11 __STD_NO_THREADS__ and __STD_NO_ATOMICS__ are not defined

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

C11 __STD_NO_THREADS__ and __STD_NO_ATOMICS__ are not defined

UnknownGamer40464 .
These macros do not appear to be defined by the compiler, resulting in code that selects for custom implementations instead using the nonexistent standard versions anyways, despite the compiler not supporting either one.

Without these definitions, I can't have TCC select for a custom implementation of the C11 threading or atomics API.

Would it be possible to have the compiler define them?

Also thanks for all your work so far keeping TCC alive.

_______________________________________________
Tinycc-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/tinycc-devel
Reply | Threaded
Open this post in threaded view
|

Re: C11 __STD_NO_THREADS__ and __STD_NO_ATOMICS__ are not defined

Christian Jullien-3

Hi,

 

C11 defines thoses macros (section 6.10.8.3) with __STDC_ prefix (not __STD_) and they exist with tcc when you pass –std=c11 flag. They are undefined with default flags.

 

See libtcc.c(1842)

 

C.

 

From: Tinycc-devel [mailto:tinycc-devel-bounces+eligis=[hidden email]] On Behalf Of UnknownGamer40464 .
Sent: Friday, January 10, 2020 05:44
To: [hidden email]
Subject: [Tinycc-devel] C11 __STD_NO_THREADS__ and __STD_NO_ATOMICS__ are not defined

 

These macros do not appear to be defined by the compiler, resulting in code that selects for custom implementations instead using the nonexistent standard versions anyways, despite the compiler not supporting either one.

 

Without these definitions, I can't have TCC select for a custom implementation of the C11 threading or atomics API.

 

Would it be possible to have the compiler define them?

 

Also thanks for all your work so far keeping TCC alive.


_______________________________________________
Tinycc-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/tinycc-devel
Reply | Threaded
Open this post in threaded view
|

Re: C11 __STD_NO_THREADS__ and __STD_NO_ATOMICS__ are not defined

UnknownGamer40464 .
Oh whoops.

You're right, sorry for wasting time.

Thanks for responding.

On Fri, Jan 10, 2020 at 12:12 AM Christian Jullien <[hidden email]> wrote:

Hi,

 

C11 defines thoses macros (section 6.10.8.3) with __STDC_ prefix (not __STD_) and they exist with tcc when you pass –std=c11 flag. They are undefined with default flags.

 

See libtcc.c(1842)

 

C.

 

From: Tinycc-devel [mailto:[hidden email]=[hidden email]] On Behalf Of UnknownGamer40464 .
Sent: Friday, January 10, 2020 05:44
To: [hidden email]
Subject: [Tinycc-devel] C11 __STD_NO_THREADS__ and __STD_NO_ATOMICS__ are not defined

 

These macros do not appear to be defined by the compiler, resulting in code that selects for custom implementations instead using the nonexistent standard versions anyways, despite the compiler not supporting either one.

 

Without these definitions, I can't have TCC select for a custom implementation of the C11 threading or atomics API.

 

Would it be possible to have the compiler define them?

 

Also thanks for all your work so far keeping TCC alive.

_______________________________________________
Tinycc-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/tinycc-devel

_______________________________________________
Tinycc-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/tinycc-devel