The NetBSD Project

CVS log for src/lib/libc/thread-stub/thread-stub.c

[BACK] Up to [cvs.NetBSD.org] / src / lib / libc / thread-stub

Request diff between arbitrary revisions


Default branch: MAIN
Current tag: MAIN


Revision 1.32 / (download) - annotate - [select for diffs], Tue Apr 19 20:32:16 2022 UTC (2 years ago) by rillig
Branch: MAIN
CVS Tags: netbsd-10-base, netbsd-10-0-RELEASE, netbsd-10-0-RC6, netbsd-10-0-RC5, netbsd-10-0-RC4, netbsd-10-0-RC3, netbsd-10-0-RC2, netbsd-10-0-RC1, netbsd-10, HEAD
Changes since 1.31: +3 -3 lines
Diff to previous 1.31 (colored) to selected 1.17 (colored)

lib: remove CONSTCOND comment

Since 2021-01-31, lint doesn't need it anymore for the common pattern of
'do ... while (0)'.

Revision 1.31 / (download) - annotate - [select for diffs], Sat Feb 6 00:08:58 2021 UTC (3 years, 2 months ago) by jdolecek
Branch: MAIN
CVS Tags: cjep_sun2x-base1, cjep_sun2x-base, cjep_sun2x, cjep_staticlib_x-base1, cjep_staticlib_x-base, cjep_staticlib_x
Changes since 1.30: +6 -5 lines
Diff to previous 1.30 (colored) to selected 1.17 (colored)

change libc sched_yield() stub to actually still call the syscall
instead of doing nothing when app is not linked with pthread; this matches
other systems

suggested by Mateusz Guzik in:
http://mail-index.netbsd.org/tech-kern/2020/07/19/msg026620.html

Revision 1.30 / (download) - annotate - [select for diffs], Tue Jan 14 18:18:59 2020 UTC (4 years, 3 months ago) by kamil
Branch: MAIN
CVS Tags: phil-wifi-20200421, phil-wifi-20200411, phil-wifi-20200406, is-mlppp-base, is-mlppp
Changes since 1.29: +5 -3 lines
Diff to previous 1.29 (colored) to selected 1.17 (colored)

Adjust the error return value of pthread_sigmask for !libpthread usage

Instead of returning -1, return errno on error.

Catch up after the fix in libpthread by Andrew Doran in 2008
in lib/libpthread/pthread_misc.c r.1.9.

It's an open question whether this function shall be used without linked
in the POSIX thread library.

Detected by Bruno Haible (GNU) and documented in gnulib in commit
"pthread_sigmask: Avoid test failure on NetBSD 8.0. " r. 4d16a83b0c1fcb6c.

Revision 1.29 / (download) - annotate - [select for diffs], Tue Mar 5 01:35:52 2019 UTC (5 years, 1 month ago) by christos
Branch: MAIN
CVS Tags: phil-wifi-20191119, phil-wifi-20190609, netbsd-9-base, netbsd-9-3-RELEASE, netbsd-9-2-RELEASE, netbsd-9-1-RELEASE, netbsd-9-0-RELEASE, netbsd-9-0-RC2, netbsd-9-0-RC1
Branch point for: netbsd-9
Changes since 1.28: +4 -9 lines
Diff to previous 1.28 (colored) to selected 1.17 (colored)

Transfer all the keys that were created in the libc stub implementation
to the pthread tsd implementation when the main thread is created.
This corrects a problem where a process created keys before libpthread
was loaded (either from the libc constructor or because libpthread
was dlopened later). This fixes a problem with jemalloc which creates
keys in the constructor.

Revision 1.28 / (download) - annotate - [select for diffs], Mon Oct 31 18:10:11 2016 UTC (7 years, 5 months ago) by kamil
Branch: MAIN
CVS Tags: prg-localcount2-base3, prg-localcount2-base2, prg-localcount2-base1, prg-localcount2-base, prg-localcount2, phil-wifi-base, pgoyette-localcount-20170426, pgoyette-localcount-20170320, pgoyette-localcount-20170107, pgoyette-localcount-20161104, pgoyette-compat-merge-20190127, pgoyette-compat-base, pgoyette-compat-20190127, pgoyette-compat-20190118, pgoyette-compat-1226, pgoyette-compat-1126, pgoyette-compat-1020, pgoyette-compat-0930, pgoyette-compat-0906, pgoyette-compat-0728, pgoyette-compat-0625, pgoyette-compat-0521, pgoyette-compat-0502, pgoyette-compat-0422, pgoyette-compat-0415, pgoyette-compat-0407, pgoyette-compat-0330, pgoyette-compat-0322, pgoyette-compat-0315, pgoyette-compat, perseant-stdc-iso10646-base, perseant-stdc-iso10646, netbsd-8-base, netbsd-8-2-RELEASE, netbsd-8-1-RELEASE, netbsd-8-1-RC1, netbsd-8-0-RELEASE, netbsd-8-0-RC2, netbsd-8-0-RC1, netbsd-8, matt-nb8-mediatek-base, matt-nb8-mediatek, bouyer-socketcan-base1, bouyer-socketcan-base, bouyer-socketcan
Branch point for: phil-wifi
Changes since 1.27: +4 -2 lines
Diff to previous 1.27 (colored) to selected 1.17 (colored)

Add CHECK_NOT_THREADED() in __libc_mutexattr_settype_stub()

This makes this function consistent with __libc_mutex_catchall_stub()
and others in the same group.

Approved by <christos>.

Revision 1.27 / (download) - annotate - [select for diffs], Tue May 28 17:29:41 2013 UTC (10 years, 10 months ago) by christos
Branch: MAIN
CVS Tags: yamt-pagecache-base9, tls-maxphys-base, tls-earlyentropy-base, tls-earlyentropy, riastradh-xf86-video-intel-2-7-1-pre-2-21-15, riastradh-drm2-base3, riastradh-drm2-base2, riastradh-drm2-base1, riastradh-drm2-base, riastradh-drm2, pgoyette-localcount-base, pgoyette-localcount-20160806, pgoyette-localcount-20160726, netbsd-7-nhusb-base-20170116, netbsd-7-nhusb-base, netbsd-7-nhusb, netbsd-7-base, netbsd-7-2-RELEASE, netbsd-7-1-RELEASE, netbsd-7-1-RC2, netbsd-7-1-RC1, netbsd-7-1-2-RELEASE, netbsd-7-1-1-RELEASE, netbsd-7-1, netbsd-7-0-RELEASE, netbsd-7-0-RC3, netbsd-7-0-RC2, netbsd-7-0-RC1, netbsd-7-0-2-RELEASE, netbsd-7-0-1-RELEASE, netbsd-7-0, netbsd-7, localcount-20160914
Branch point for: pgoyette-localcount
Changes since 1.26: +3 -3 lines
Diff to previous 1.26 (colored) to selected 1.17 (colored)

mark __libc_thr_exit_stub dead here too

Revision 1.26 / (download) - annotate - [select for diffs], Sat Apr 27 20:36:47 2013 UTC (10 years, 11 months ago) by joerg
Branch: MAIN
Changes since 1.25: +25 -2 lines
Diff to previous 1.25 (colored) to selected 1.17 (colored)

Provide stubs for pthread_detach/pthread_join.

Revision 1.25 / (download) - annotate - [select for diffs], Fri Apr 12 18:14:22 2013 UTC (11 years ago) by joerg
Branch: MAIN
Changes since 1.24: +3 -4 lines
Diff to previous 1.24 (colored) to selected 1.17 (colored)

Weak alias directly to the catchall stub and don't strong alias twice.

Revision 1.24 / (download) - annotate - [select for diffs], Fri Apr 5 20:15:42 2013 UTC (11 years ago) by christos
Branch: MAIN
Changes since 1.23: +2 -23 lines
Diff to previous 1.23 (colored) to selected 1.17 (colored)

split init and errno to a separate file. No point in growing rtld 10K.

Revision 1.23 / (download) - annotate - [select for diffs], Thu Mar 21 16:49:11 2013 UTC (11 years, 1 month ago) by christos
Branch: MAIN
CVS Tags: agc-symver-base, agc-symver
Changes since 1.22: +28 -34 lines
Diff to previous 1.22 (colored) to selected 1.17 (colored)

- Allow libpthread to be dlopened again, by providing libc stubs to libpthread.
- Fail if the dlopened libpthread does pthread_create(). From manu@
- Discussed at length in the mailing lists; approved by core@
- This was chosen as the least intrusive patch that will provide
  the necessary functionality.
XXX: pullup to 6

Revision 1.22 / (download) - annotate - [select for diffs], Fri Sep 16 16:05:59 2011 UTC (12 years, 7 months ago) by joerg
Branch: MAIN
CVS Tags: yamt-pagecache-tag8, yamt-pagecache-base8, yamt-pagecache-base7, yamt-pagecache-base6, yamt-pagecache-base5, yamt-pagecache-base4, yamt-pagecache-base3, yamt-pagecache-base2, yamt-pagecache-base, netbsd-6-base, netbsd-6-1-RC3, netbsd-6-1-RC2, netbsd-6-1-RC1, netbsd-6-0-RELEASE, netbsd-6-0-RC2, netbsd-6-0-RC1, netbsd-6-0-6-RELEASE, netbsd-6-0-5-RELEASE, netbsd-6-0-4-RELEASE, netbsd-6-0-3-RELEASE, netbsd-6-0-2-RELEASE, netbsd-6-0-1-RELEASE, netbsd-6-0, matt-nb6-plus-nbase, matt-nb6-plus-base, matt-nb6-plus
Branch point for: yamt-pagecache, tls-maxphys, netbsd-6
Changes since 1.21: +3 -3 lines
Diff to previous 1.21 (colored) to selected 1.17 (colored)

Use __dead

Revision 1.21 / (download) - annotate - [select for diffs], Fri Jan 30 23:21:03 2009 UTC (15 years, 2 months ago) by ad
Branch: MAIN
CVS Tags: matt-premerge-20091211, matt-mips64-premerge-20101231, jym-xensuspend-nbase, jym-xensuspend-base, jym-xensuspend, cherry-xenmp-base, cherry-xenmp, bouyer-quota2-nbase, bouyer-quota2-base, bouyer-quota2
Changes since 1.20: +4 -4 lines
Diff to previous 1.20 (colored) to selected 1.17 (colored)

Make threaded programs die correctly:

kill(getpid(), SIGFOO) -> raise(SIGFOO)

Revision 1.20 / (download) - annotate - [select for diffs], Mon Apr 28 20:23:01 2008 UTC (15 years, 11 months ago) by martin
Branch: MAIN
CVS Tags: yamt-pf42-base4, yamt-pf42-base3, yamt-pf42-base2, wrstuden-revivesa-base-3, wrstuden-revivesa-base-2, wrstuden-revivesa-base-1, wrstuden-revivesa-base, wrstuden-revivesa, netbsd-5-base, netbsd-5-0-RC1, matt-mips64-base2, hpcarm-cleanup-nbase, christos-time_t-nbase, christos-time_t-base
Branch point for: netbsd-5, christos-time_t
Changes since 1.19: +2 -9 lines
Diff to previous 1.19 (colored) to selected 1.17 (colored)

Remove clause 3 and 4 from TNF licenses

Revision 1.19 / (download) - annotate - [select for diffs], Fri Dec 14 17:06:07 2007 UTC (16 years, 4 months ago) by christos
Branch: MAIN
CVS Tags: yamt-pf42-baseX, yamt-pf42-base, matt-armv6-nbase, matt-armv6-base, keiichi-mipv6-base, keiichi-mipv6, hpcarm-cleanup-base
Branch point for: yamt-pf42
Changes since 1.18: +3 -2 lines
Diff to previous 1.18 (colored) to selected 1.17 (colored)

add fw decl.

Revision 1.18 / (download) - annotate - [select for diffs], Fri Dec 14 17:04:28 2007 UTC (16 years, 4 months ago) by christos
Branch: MAIN
Changes since 1.17: +4 -4 lines
Diff to previous 1.17 (colored)

fix obvious bogon [can't alias symbol to itself]

Revision 1.17 / (download) - annotate - [selected], Tue Nov 27 20:58:26 2007 UTC (16 years, 4 months ago) by ad
Branch: MAIN
CVS Tags: cube-autoconf-base, cube-autoconf
Changes since 1.16: +10 -2 lines
Diff to previous 1.16 (colored)

Add thr_curcpu(), pthread_curcpu_np().

Revision 1.16 / (download) - annotate - [select for diffs], Wed Nov 14 19:28:23 2007 UTC (16 years, 5 months ago) by drochner
Branch: MAIN
Changes since 1.15: +12 -2 lines
Diff to previous 1.15 (colored) to selected 1.17 (colored)

Add pthread_equal() to libc stubs; this makes a lot of sense for
threadsafe libraries implementing own locking functions.
Ride on yesterday's minor version bumps.

Revision 1.15 / (download) - annotate - [select for diffs], Tue Nov 13 15:21:20 2007 UTC (16 years, 5 months ago) by ad
Branch: MAIN
Changes since 1.14: +16 -2 lines
Diff to previous 1.14 (colored) to selected 1.17 (colored)

- stack_protector.c doesn't really belong under sys/. Add a new directory
  for misc support routines and put it there.
- Add a libc constructor. Use this to initialize threading and the
  stack protector stuff. libpthread cannot be initialized safely using
  its own constructor because libc and libpthread are deeply intertwined.
  PR bin/37347

Revision 1.14 / (download) - annotate - [select for diffs], Tue Nov 29 03:12:00 2005 UTC (18 years, 4 months ago) by christos
Branch: MAIN
CVS Tags: wrstuden-fixsa-newbase, wrstuden-fixsa-base-1, wrstuden-fixsa-base, wrstuden-fixsa, netbsd-4-base, netbsd-4-0-RELEASE, netbsd-4-0-RC5, netbsd-4-0-RC4, netbsd-4-0-RC3, netbsd-4-0-RC2, netbsd-4-0-RC1, netbsd-4-0-1-RELEASE, netbsd-4-0, netbsd-4, matt-mips64-base, matt-mips64, matt-armv6-prevmlocking, hpcarm-cleanup, abandoned-netbsd-4-base, abandoned-netbsd-4
Branch point for: matt-armv6
Changes since 1.13: +3 -4 lines
Diff to previous 1.13 (colored) to selected 1.17 (colored)

WARNS=4

Revision 1.13 / (download) - annotate - [select for diffs], Sun Jun 12 05:21:28 2005 UTC (18 years, 10 months ago) by lukem
Branch: MAIN
Changes since 1.12: +6 -1 lines
Diff to previous 1.12 (colored) to selected 1.17 (colored)

Add missing __RCSID()

Revision 1.12 / (download) - annotate - [select for diffs], Tue Dec 14 00:21:40 2004 UTC (19 years, 4 months ago) by nathanw
Branch: MAIN
CVS Tags: netbsd-3-base, netbsd-3-1-RELEASE, netbsd-3-1-RC4, netbsd-3-1-RC3, netbsd-3-1-RC2, netbsd-3-1-RC1, netbsd-3-1-1-RELEASE, netbsd-3-1, netbsd-3-0-RELEASE, netbsd-3-0-RC6, netbsd-3-0-RC5, netbsd-3-0-RC4, netbsd-3-0-RC3, netbsd-3-0-RC2, netbsd-3-0-RC1, netbsd-3-0-3-RELEASE, netbsd-3-0-2-RELEASE, netbsd-3-0-1-RELEASE, netbsd-3-0, netbsd-3
Changes since 1.11: +2 -2 lines
Diff to previous 1.11 (colored) to selected 1.17 (colored)

Fix the __libc_thr_yield_stub() signature.

Revision 1.11 / (download) - annotate - [select for diffs], Mon Dec 13 16:07:13 2004 UTC (19 years, 4 months ago) by nathanw
Branch: MAIN
Changes since 1.10: +3 -3 lines
Diff to previous 1.10 (colored) to selected 1.17 (colored)

The __libc_thr_yield_stub() for scched_yield() should return int (and
a 0), not void.

Revision 1.10 / (download) - annotate - [select for diffs], Mon Dec 6 18:58:12 2004 UTC (19 years, 4 months ago) by nathanw
Branch: MAIN
Changes since 1.9: +2 -10 lines
Diff to previous 1.9 (colored) to selected 1.17 (colored)

Implement __libc_thr_sigsetmask_stub() in terms of sigprocmask(),
instead of having a dummy function.

Revision 1.9 / (download) - annotate - [select for diffs], Fri Jul 18 21:44:38 2003 UTC (20 years, 9 months ago) by nathanw
Branch: MAIN
CVS Tags: netbsd-2-base, netbsd-2-1-RELEASE, netbsd-2-1-RC6, netbsd-2-1-RC5, netbsd-2-1-RC4, netbsd-2-1-RC3, netbsd-2-1-RC2, netbsd-2-1-RC1, netbsd-2-1, netbsd-2-0-base, netbsd-2-0-RELEASE, netbsd-2-0-RC5, netbsd-2-0-RC4, netbsd-2-0-RC3, netbsd-2-0-RC2, netbsd-2-0-RC1, netbsd-2-0-3-RELEASE, netbsd-2-0-2-RELEASE, netbsd-2-0-1-RELEASE, netbsd-2-0, netbsd-2
Changes since 1.8: +17 -1 lines
Diff to previous 1.8 (colored) to selected 1.17 (colored)

Add a stub for setcancelstate().

Revision 1.8 / (download) - annotate - [select for diffs], Sat Mar 1 22:11:40 2003 UTC (21 years, 1 month ago) by matt
Branch: MAIN
Changes since 1.7: +2 -1 lines
Diff to previous 1.7 (colored) to selected 1.17 (colored)

Add #include <stdlib.h> for exit definition.

Revision 1.7 / (download) - annotate - [select for diffs], Mon Jan 20 01:58:54 2003 UTC (21 years, 3 months ago) by thorpej
Branch: MAIN
Changes since 1.6: +44 -20 lines
Diff to previous 1.6 (colored) to selected 1.17 (colored)

Simple TSD implementation, since some thread-safe libraries want
to use it.

Revision 1.6 / (download) - annotate - [select for diffs], Mon Jan 20 01:30:15 2003 UTC (21 years, 3 months ago) by thorpej
Branch: MAIN
Changes since 1.5: +2 -2 lines
Diff to previous 1.5 (colored) to selected 1.17 (colored)

Make thr_self() not return NULL.

Revision 1.5 / (download) - annotate - [select for diffs], Sun Jan 19 21:58:23 2003 UTC (21 years, 3 months ago) by thorpej
Branch: MAIN
Changes since 1.4: +43 -2 lines
Diff to previous 1.4 (colored) to selected 1.17 (colored)

Add some threadlib stubs that are used by X:
* thr_create() (stub in libc aborts)
* thr_exit() (stub in libc calls exit())
* thr_yield() (stub in libc does nothing)

Also make the libc thr_self() stub not abort.

XXX Should we add thrattr_*() stubs for setting the detach-state?

Revision 1.4 / (download) - annotate - [select for diffs], Sun Jan 19 20:46:12 2003 UTC (21 years, 3 months ago) by thorpej
Branch: MAIN
Changes since 1.3: +29 -1 lines
Diff to previous 1.3 (colored) to selected 1.17 (colored)

Add mutexattr_init(), mutexattr_destroy(), and mutexattr_settype() (recursive
mutexes are used by the X libraries).

Revision 1.3 / (download) - annotate - [select for diffs], Sun Jan 19 19:48:45 2003 UTC (21 years, 3 months ago) by thorpej
Branch: MAIN
Changes since 1.2: +7 -6 lines
Diff to previous 1.2 (colored) to selected 1.17 (colored)

Make the libc thr_once() stub functional.

Revision 1.2 / (download) - annotate - [select for diffs], Sat Jan 18 11:33:19 2003 UTC (21 years, 3 months ago) by thorpej
Branch: MAIN
Changes since 1.1: +333 -0 lines
Diff to previous 1.1 (colored) to selected 1.17 (colored)

Merge the nathanw_sa branch.

Revision 1.1, Wed Jan 8 19:34:21 2003 UTC (21 years, 3 months ago) by thorpej
Branch: MAIN
CVS Tags: nathanw_sa_before_merge, nathanw_sa_base
Branch point for: nathanw_sa
FILE REMOVED

file thread-stub.c was initially added on branch nathanw_sa.

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.




CVSweb <webmaster@jp.NetBSD.org>