From 1acbd4da02eb82a035c00a2f484364453469ff06 Mon Sep 17 00:00:00 2001 From: Michael Forney Date: Thu, 27 Jun 2019 15:16:39 -0700 Subject: Detect TLS support in compiler --- probe/HAVE__THREAD_LOCAL | 4 ++++ probe/gen.lua | 1 + 2 files changed, 5 insertions(+) create mode 100644 probe/HAVE__THREAD_LOCAL (limited to 'probe') diff --git a/probe/HAVE__THREAD_LOCAL b/probe/HAVE__THREAD_LOCAL new file mode 100644 index 00000000..fe1a4e57 --- /dev/null +++ b/probe/HAVE__THREAD_LOCAL @@ -0,0 +1,4 @@ +_Thread_local int x; +int main(void) { + return x; +} diff --git a/probe/gen.lua b/probe/gen.lua index 321f283c..56d470ec 100644 --- a/probe/gen.lua +++ b/probe/gen.lua @@ -4,6 +4,7 @@ end probe('HAVE_IMMINTRIN_H') probe('HAVE__MM_MOVEMASK_EPI8') +probe('HAVE__THREAD_LOCAL') local function probesize(var) build('probesize', '$outdir/'..var, {'$dir/'..var, '|', 'scripts/probe-size.sh'}, {var=var}) -- cgit v1.2.3