<feed xmlns='http://www.w3.org/2005/Atom'>
<title>gcc.git/libatomic/libatomic_i.h, branch master</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/gcc.git/'/>
<entry>
<title>Update copyright years.</title>
<updated>2025-01-02T10:59:57+00:00</updated>
<author>
<name>Jakub Jelinek</name>
<email>jakub@redhat.com</email>
</author>
<published>2025-01-02T10:59:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/gcc.git/commit/?id=6441eb6dc020faae0672ea724dfdb38c6a9bf6a1'/>
<id>6441eb6dc020faae0672ea724dfdb38c6a9bf6a1</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Update copyright years.</title>
<updated>2024-01-03T11:19:35+00:00</updated>
<author>
<name>Jakub Jelinek</name>
<email>jakub@redhat.com</email>
</author>
<published>2024-01-03T11:19:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/gcc.git/commit/?id=a945c346f57ba40fc80c14ac59be0d43624e559d'/>
<id>a945c346f57ba40fc80c14ac59be0d43624e559d</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Update copyright years.</title>
<updated>2023-01-16T10:52:17+00:00</updated>
<author>
<name>Jakub Jelinek</name>
<email>jakub@redhat.com</email>
</author>
<published>2023-01-16T10:50:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/gcc.git/commit/?id=83ffe9cde7fe0b4deb0d1b54175fd9b19c38179c'/>
<id>83ffe9cde7fe0b4deb0d1b54175fd9b19c38179c</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Update copyright years.</title>
<updated>2022-01-03T09:42:10+00:00</updated>
<author>
<name>Jakub Jelinek</name>
<email>jakub@redhat.com</email>
</author>
<published>2022-01-03T09:42:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/gcc.git/commit/?id=7adcbafe45f8001b698967defe682687b52c0007'/>
<id>7adcbafe45f8001b698967defe682687b52c0007</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Update copyright years.</title>
<updated>2021-01-04T09:26:59+00:00</updated>
<author>
<name>Jakub Jelinek</name>
<email>jakub@redhat.com</email>
</author>
<published>2021-01-04T09:26:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/gcc.git/commit/?id=99dee82307f1e163e150c9c810452979994047ce'/>
<id>99dee82307f1e163e150c9c810452979994047ce</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[libatomic] Add nvptx support</title>
<updated>2020-09-11T10:06:15+00:00</updated>
<author>
<name>Tom de Vries</name>
<email>tdevries@suse.de</email>
</author>
<published>2020-09-07T08:47:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/gcc.git/commit/?id=15545563128f0240192c263522d4a36b7f86250f'/>
<id>15545563128f0240192c263522d4a36b7f86250f</id>
<content type='text'>
Add nvptx support to libatomic.

Given that atomic_test_and_set is not implemented for nvptx (PR96964), the
compiler translates __atomic_test_and_set falling back onto the "Failing all
else, assume a single threaded environment and simply perform the operation"
case in expand_atomic_test_and_set, so it doesn't map onto an actual atomic
operation.

Still, that counts as supported for the configure test of libatomic, so we
end up with HAVE_ATOMIC_TAS_1/2/4/8/16 == 1, and the corresponding
__atomic_test_and_set_1/2/4/8/16 in libatomic all using that non-atomic
implementation.

Fix this by adding an atomic_test_and_set expansion for nvptx, that uses
libatomics __atomic_test_and_set_1.

This again makes the configure tests for HAVE_ATOMIC_TAS_1/2/4/8/16 fail, so
instead we use this case in tas_n.c:
...
/* If this type is smaller than word-sized, fall back to a word-sized
   compare-and-swap loop.  */
bool
SIZE(libat_test_and_set) (UTYPE *mptr, int smodel)
...
which for __atomic_test_and_set_8 uses INVERT_MASK_8.

Add INVERT_MASK_8 in libatomic_i.h, as well as MASK_8.

Tested libatomic testsuite on nvptx.

gcc/ChangeLog:

	PR target/96964
	* config/nvptx/nvptx.md (define_expand "atomic_test_and_set"): New
	expansion.

libatomic/ChangeLog:

	PR target/96898
	* configure.tgt: Add nvptx.
	* libatomic_i.h (MASK_8, INVERT_MASK_8): New macro definition.
	* config/nvptx/host-config.h: New file.
	* config/nvptx/lock.c: New file.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add nvptx support to libatomic.

Given that atomic_test_and_set is not implemented for nvptx (PR96964), the
compiler translates __atomic_test_and_set falling back onto the "Failing all
else, assume a single threaded environment and simply perform the operation"
case in expand_atomic_test_and_set, so it doesn't map onto an actual atomic
operation.

Still, that counts as supported for the configure test of libatomic, so we
end up with HAVE_ATOMIC_TAS_1/2/4/8/16 == 1, and the corresponding
__atomic_test_and_set_1/2/4/8/16 in libatomic all using that non-atomic
implementation.

Fix this by adding an atomic_test_and_set expansion for nvptx, that uses
libatomics __atomic_test_and_set_1.

This again makes the configure tests for HAVE_ATOMIC_TAS_1/2/4/8/16 fail, so
instead we use this case in tas_n.c:
...
/* If this type is smaller than word-sized, fall back to a word-sized
   compare-and-swap loop.  */
bool
SIZE(libat_test_and_set) (UTYPE *mptr, int smodel)
...
which for __atomic_test_and_set_8 uses INVERT_MASK_8.

Add INVERT_MASK_8 in libatomic_i.h, as well as MASK_8.

Tested libatomic testsuite on nvptx.

gcc/ChangeLog:

	PR target/96964
	* config/nvptx/nvptx.md (define_expand "atomic_test_and_set"): New
	expansion.

libatomic/ChangeLog:

	PR target/96898
	* configure.tgt: Add nvptx.
	* libatomic_i.h (MASK_8, INVERT_MASK_8): New macro definition.
	* config/nvptx/host-config.h: New file.
	* config/nvptx/lock.c: New file.
</pre>
</div>
</content>
</entry>
<entry>
<title>Update copyright years.</title>
<updated>2020-01-01T11:51:42+00:00</updated>
<author>
<name>Jakub Jelinek</name>
<email>jakub@gcc.gnu.org</email>
</author>
<published>2020-01-01T11:51:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/gcc.git/commit/?id=8d9254fc8aa32619f640efb01cfe87cc6cdc9ce1'/>
<id>8d9254fc8aa32619f640efb01cfe87cc6cdc9ce1</id>
<content type='text'>
From-SVN: r279813
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
From-SVN: r279813
</pre>
</div>
</content>
</entry>
<entry>
<title>Update copyright years.</title>
<updated>2019-01-01T12:31:55+00:00</updated>
<author>
<name>Jakub Jelinek</name>
<email>jakub@gcc.gnu.org</email>
</author>
<published>2019-01-01T12:31:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/gcc.git/commit/?id=a5544970246db337977bb8b69ab120e9ef209317'/>
<id>a5544970246db337977bb8b69ab120e9ef209317</id>
<content type='text'>
From-SVN: r267494
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
From-SVN: r267494
</pre>
</div>
</content>
</entry>
<entry>
<title>Update copyright years.</title>
<updated>2018-01-03T10:03:58+00:00</updated>
<author>
<name>Jakub Jelinek</name>
<email>jakub@gcc.gnu.org</email>
</author>
<published>2018-01-03T10:03:58+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/gcc.git/commit/?id=85ec4feb11167c9e4489361bf2399a20afbe52c8'/>
<id>85ec4feb11167c9e4489361bf2399a20afbe52c8</id>
<content type='text'>
From-SVN: r256169
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
From-SVN: r256169
</pre>
</div>
</content>
</entry>
<entry>
<title>Makefile.am (ARCH_AARCH64_LINUX): Add IFUNC_OPTIONS and libatomic_la_LIBADD.</title>
<updated>2017-12-05T00:49:09+00:00</updated>
<author>
<name>Steve Ellcey</name>
<email>sellcey@cavium.com</email>
</author>
<published>2017-12-05T00:49:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/gcc.git/commit/?id=141abc6f1e5a6a2de0a1ee97b63d56ee50b85a66'/>
<id>141abc6f1e5a6a2de0a1ee97b63d56ee50b85a66</id>
<content type='text'>
2017-12-04  Steve Ellcey  &lt;sellcey@cavium.com&gt;

	* Makefile.am (ARCH_AARCH64_LINUX): Add IFUNC_OPTIONS and
	libatomic_la_LIBADD.
	* config/linux/aarch64/host-config.h: New file.
	* configure.ac (IFUNC_RESOLVER_ARGS): Define.
	(ARCH_AARCH64_LINUX): New conditional for IFUNC builds.
	* configure.tgt (aarch64): Set ARCH and try_ifunc.
	(aarch64*-*-linux*) Update config_path.
	(aarch64*-*-linux*) Set IFUNC_RESOLVER_ARGS.
	* libatomic_i.h (GEN_SELECTOR): Add IFUNC_RESOLVER_ARGS argument.
	* Makefile.in: Regenerate.
	* auto-config.h.in: Regenerate.
	* configure: Regenerate.

From-SVN: r255399
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
2017-12-04  Steve Ellcey  &lt;sellcey@cavium.com&gt;

	* Makefile.am (ARCH_AARCH64_LINUX): Add IFUNC_OPTIONS and
	libatomic_la_LIBADD.
	* config/linux/aarch64/host-config.h: New file.
	* configure.ac (IFUNC_RESOLVER_ARGS): Define.
	(ARCH_AARCH64_LINUX): New conditional for IFUNC builds.
	* configure.tgt (aarch64): Set ARCH and try_ifunc.
	(aarch64*-*-linux*) Update config_path.
	(aarch64*-*-linux*) Set IFUNC_RESOLVER_ARGS.
	* libatomic_i.h (GEN_SELECTOR): Add IFUNC_RESOLVER_ARGS argument.
	* Makefile.in: Regenerate.
	* auto-config.h.in: Regenerate.
	* configure: Regenerate.

From-SVN: r255399
</pre>
</div>
</content>
</entry>
</feed>
