[PATCH] libgomp: Add OMPD functions defined in Thread Handles.

2020-07-30 Thread y2s1982 via Gcc-patches
This patch adds functions defined in the section 5.5.5 Thread Handles in OpenMP API Specification 5.0. It currently omits CUDA support, and hard-codes the offset and sizeof values. I would appreciate any suggestions. 2020-07-30 Tony Sim libgomp/ChangeLog: * Makefile.am (libgompd_la_SO

Re: [PATCH] libgomp: Add helper functions for memory handling.

2020-07-27 Thread y2s1982 via Gcc-patches
Hello Jakub, Thanks for the reply. I apparently need further clarification. On Mon, Jul 27, 2020 at 12:36 PM Jakub Jelinek wrote: > On Sat, Jul 25, 2020 at 11:03:27AM -0400, y2s1982 via Gcc-patches wrote: > > This patch adds few helper functions aims to improve readability of >

[PATCH] libgomp: Add helper functions for memory handling.

2020-07-25 Thread y2s1982 via Gcc-patches
This patch adds few helper functions aims to improve readability of fetching addresses, sizes, and values. It also proposes a syntax for querying these information through the callback functions, similar to that of LLVM implementation. The syntax format is _, or __. '_' is the delimiter between fie

[PATCH] libgomp: Add helper functions for memory handling.

2020-07-20 Thread y2s1982 via Gcc-patches
This patch adds few helper functions aims to improve readability of fetching addresses, sizes, and values. It also proposes a syntax for querying these information through the callback functions, similar to that of LLVM implementation. The syntax format is _, or __. '_' is the delimiter between fie

Re: [PATCH] libgomp: Add OMPD Address Space Information functions.

2020-07-14 Thread y2s1982 via Gcc-patches
ny Sim On Tue, Jul 14, 2020 at 5:57 AM Jakub Jelinek wrote: > On Thu, Jul 09, 2020 at 07:01:00PM -0400, y2s1982 via Gcc-patches wrote: > > --- a/libgomp/libgompd.h > > +++ b/libgomp/libgompd.h > > @@ -47,4 +47,19 @@ typedef struct _ompd_aspace_h

[PATCH] libgomp: Add OMPD Address Space Information functions.

2020-07-14 Thread y2s1982 via Gcc-patches
This patch adds Address Space Information function implementations as defined in section 5.5.4 of OpenMP API Specification 5.0. It also defines a struct that stores various information used by OMPD. This patch addressed all feedbacks. 2020-07-14 Tony Sim libgomp/ChangeLog: * Makefile

Re: [PATCH] libgomp: Add OMPD functions in 5.5.6 and related data types.

2020-07-14 Thread y2s1982 via Gcc-patches
Hello Jakub, On Tue, Jul 14, 2020 at 6:07 AM Jakub Jelinek wrote: > On Sat, Jul 11, 2020 at 06:05:36PM -0400, y2s1982 wrote: > > 2020-07-11 Tony Sim > > > > libgomp/ChangeLog: > > > > * libgompd.h (ompd_thread_handle_t): Add. > > (ompd_parallel_handle_t): Add. > > (ompd_tas

Re: [PATCH] libgomp: Add OMPD Address Space Information functions.

2020-07-14 Thread y2s1982 via Gcc-patches
Hello Jakub, Thank you for the detailed information. I will make those changes right away. Cheers, Tony Sim On Tue, Jul 14, 2020 at 5:57 AM Jakub Jelinek wrote: > On Thu, Jul 09, 2020 at 07:01:00PM -0400, y2s1982 via Gcc-patches wrote: > > --- a/libgomp/libgompd.h > >

[PATCH] libgomp: Add OMPD functions in 5.5.6 and related data types.

2020-07-11 Thread y2s1982 via Gcc-patches
This patch adds function definition described in the section 5.5.6 of the OpenMP API Specificiation 5.0. It also partially defines some of the handler data types related to the section. 2020-07-11 Tony Sim libgomp/ChangeLog: * libgompd.h (ompd_thread_handle_t): Add. (ompd_para

[PATCH] libgomp: Add OMPD Address Space Information functions.

2020-07-09 Thread y2s1982 via Gcc-patches
This patch adds Address Space Information function implementations as defined in section 5.5.4 of OpenMP API Specification 5.0. It also defines a struct that stores various information used by OMPD. 2020-07-09 Tony Sim libgomp/ChangeLog: * Makefile.am (libgompd_la_OBJECTS): Add ompd-a

Re: [PATCH] libgomp: Add OMPD Address Space Information functions.

2020-07-08 Thread y2s1982 . via Gcc-patches
Hello Jakub, Thank you again for detailed feedback. I had few questions. On Wed, Jul 8, 2020 at 4:42 PM Jakub Jelinek wrote: > On Wed, Jul 08, 2020 at 03:30:35PM -0400, y2s1982 wrote: > > +ompd_rc_t > > +ompd_get_omp_version (ompd_address_space_handle_t *address_space, > > + o

[PATCH] libgomp: Add OMPD Address Space Information functions.

2020-07-08 Thread y2s1982 via Gcc-patches
This patch adds Address Space Information function implementations as defined in section 5.5.4 of OpenMP API Specification 5.0. 2020-07-08 Tony Sim libgomp/ChangeLog: * Makefile.am (libgompd_la_OBJECTS): Add ompd-addr.c. * Makefile.in: Regenerate. * ompd-addr.c: New fi

Re: [PATCH] libgomp: Add OMPD process functions and datatypes.

2020-07-08 Thread y2s1982 . via Gcc-patches
Hello On Wed, Jul 8, 2020 at 5:08 AM Jakub Jelinek wrote: > On Tue, Jul 07, 2020 at 02:52:37PM -0400, y2s1982 . via Gcc-patches wrote: > > I have re-read the documentation trying to find a different solution. > > In particular, ompd_device_initialize states that > &g

[PATCH] libgomp: Add skeletal OMPD process functions and datatypes.

2020-07-08 Thread y2s1982 via Gcc-patches
This patch adds OMPD functions defined in 5.5.2 of the OpenMP 5.0 API documentation. It adds per-process and per-device functions, defines related handle data types. It also introduces ompd-types.h to Makefile. 2020-07-08 Tony Sim libgomp/ChangeLog: * Makefile.am (libgompd_la_SOURCES)

Re: [PATCH] libgomp: Add OMPD process functions and datatypes.

2020-07-07 Thread y2s1982 . via Gcc-patches
Hello, On Tue, Jul 7, 2020 at 7:46 AM Jakub Jelinek wrote: > On Tue, Jul 07, 2020 at 07:38:13AM -0400, y2s1982 . wrote: > > > I have no idea what this function is doing, but e.g. from aliasing > point of > > > view trying to access something as short/int/long long is dangerous, > and > > > there

Re: [PATCH] libgomp: Add OMPD process functions and datatypes.

2020-07-07 Thread y2s1982 . via Gcc-patches
Hello Jakub, Thank you for the review. I had some questions. On Tue, Jul 7, 2020 at 4:13 AM Jakub Jelinek wrote: > On Fri, Jul 03, 2020 at 10:43:55PM -0400, y2s1982 via Gcc-patches wrote: > > > + switch (id_size) > > +{ > > +case 1: > > +

[PATCH] libgomp: Add OMPD process functions and datatypes.

2020-07-03 Thread y2s1982 via Gcc-patches
This patch adds OMPD functions defined in 5.5.2 of the OpenMP 5.0 API documentation. It adds per-process and per-device functions, defines related handle data types, and adds a helper function for storing device id. 2020-07-03 Tony Sim libgomp/ChangeLog: * Makefile.am (libgompd_la_OBJ

Re: [PATCH] libgomp: Add OMPD per-process functions.

2020-07-03 Thread y2s1982 . via Gcc-patches
Hello, I believe I misused the write_memory() function. This function is currently used in ompd_device_initialize() to write a block of memory that represents the id of the device, stored in the handle as a pointer. I would need to resubmit the patch but I have some questions regarding the issue.

[PATCH] libgomp: Add OMPD per-process functions.

2020-07-03 Thread y2s1982 via Gcc-patches
This patch adds OMPD process and device handling functions and related data structures as described in the OMP 5.0 API documentation, section 5.5.2. 2020-07-03 Tony Sim libgomp/ChangeLog: * Makefile.am (libgompd_la_SOURCES): Add ompd-proc.c * Makefile.in: Regenerate. *

[PATCH] libgomp: defined OMPD library-wide functions.

2020-07-01 Thread y2s1982 via Gcc-patches
This patch provides an initial set of definition for the rest of library-wide OMPD functions. It addresses all feedbacks. 2020-07-01 Tony Sim libgomp/ChangeLog: * libgompd.h: Include omp-tools.h. (gompd_callbacks): New extern declaration. * ompd-lib.c (gompd_callback

Re: [PATCH] libgomp: added simple functions and tests for OMPD

2020-06-26 Thread y2s1982 . via Gcc-patches
Hello, On Fri, Jun 26, 2020 at 1:08 PM Jakub Jelinek wrote: > On Fri, Jun 26, 2020 at 12:57:59PM -0400, y2s1982 . wrote: > > > > * env.c(ompd_dll_locations_valid): Define with no compiler > > > optimization. > > > > > > Again, missing space. > > > > > > The contrib/mklog.py, which I use to

Re: [PATCH] libgomp: added simple functions and tests for OMPD

2020-06-26 Thread y2s1982 . via Gcc-patches
Hello, On Fri, Jun 26, 2020 at 5:03 AM Jakub Jelinek wrote: > Thanks, just nits, no need to repost, just commit it after you make those > changes. > > On Thu, Jun 25, 2020 at 05:58:23PM -0400, y2s1982 via Gcc-patches wrote: > > > * Makefile.am(toolexeclib_LTLIBRAR

[PATCH] libgomp: added simple functions and tests for OMPD

2020-06-25 Thread y2s1982 via Gcc-patches
From: y2s82 <1997371+y2...@users.noreply.github.com> This patch adds some unit tests for omp-tools.h header. It also adds some simple functions variables related to OMPD API versions and dll locations. It also partially defines the OMPD initialization function. More OMPD configuration is also adde

Re: [PATCH] libgomp: added simple functions and tests for OMPD

2020-06-25 Thread y2s1982 . via Gcc-patches
> > > > --- /dev/null > > +++ b/libgomp/libgompd.map > > @@ -0,0 +1,49 @@ > > +OMPD_5.0 { > > + global: > > + ompd_dll_locations_valid; > > ompd_dll_locations and ompd_dll_locations_valid both need to be exported, > but not from libgompd.so.1 but from libgomp.so.1, so they need to go into > li

Re: [PATCH] libgomp: added simple functions and tests for OMPD

2020-06-25 Thread y2s1982 . via Gcc-patches
Hello Jakub, Thank you for the feedback. I can't believe I made some careless mistakes. I am also very interested in learning some new techniques mentioned. I had some questions about them. On Thu, Jun 25, 2020 at 4:28 AM Jakub Jelinek wrote: > > > --- /dev/null > > +++ b/libgomp/libgompd.map >

[PATCH] libgomp: added simple functions and tests for OMPD

2020-06-24 Thread y2s1982 via Gcc-patches
This patch adds some unit tests for omp-tools.h header. It also adds some simple functions related to OMPD API versions. It also partially defines the OMPD initialization function. More OMPD configuration is also added into Makefile.am. 2020-06-24 Tony Sim libgomp/ChangeLog: * Makefil

Re: [PATCH] libgomp: added simple functions and tests for OMPD

2020-06-24 Thread y2s1982 . via Gcc-patches
Hello, Thank you for the tips. I have some follow up questions. :) On Wed, Jun 24, 2020 at 5:25 AM Jakub Jelinek wrote: > > libgomp/ChangeLog: > > > > * Makefile.am (toolexeclib_LTLIBRARIES and related): Add > libgompd.la. > > Please spell out all the changes. I.e. > * Makefile.a

[PATCH] libgomp: added simple functions and tests for OMPD

2020-06-23 Thread y2s1982 via Gcc-patches
This patch adds some unit tests for omp-tools.h header. It also adds some simple functions related to OMPD API versions. It also partially defines the OMPD initialization function. 2020-06-23 Tony Sim libgomp/ChangeLog: * Makefile.am (toolexeclib_LTLIBRARIES and related): Add libgompd

[PATCH] libgomp: added partial omp-tools.h for OMPD.

2020-06-13 Thread y2s1982 via Gcc-patches
This patch adds a partial omp-tools.h from OpenMP which describes function prototypes and data types used for OMPD. All feedback has been addressed. 2020-06-13 Tony Sim libgomp/ChangeLog: * Makefile.am (nodist_libsubinclude_HEADERS): Add omp-tools.h. * Makefile.in: Regenerate

Re: [PATCH] libgomp: added a partial omp-tools.h for OMPD

2020-06-13 Thread y2s1982 . via Gcc-patches
Hi Jakub, When I compiled the header after adding the missing typedefs, I got warnings about nothrow attribute being ignored on typedef function declarations. Should I remove them from typedef function declarations? Cheers, Tony Sim On Sat, Jun 13, 2020 at 10:15 AM y2s1982 . wrote: > Hi Jaku

Re: [PATCH] libgomp: added a partial omp-tools.h for OMPD

2020-06-13 Thread y2s1982 . via Gcc-patches
Hi Jakub, Thank you for the valuable feedback. I especially liked the tip on how to compile the header. I will make a new patch and submit it. Cheers, Tony Sim On Sat, Jun 13, 2020 at 5:13 AM Jakub Jelinek wrote: > On Sat, Jun 13, 2020 at 11:06:52AM +0200, Jakub Jelinek via Gcc-patches > wrot

[PATCH] libgomp: added a partial omp-tools.h for OMPD

2020-06-12 Thread y2s1982 via Gcc-patches
This patch adds a partial omp-tools.h from OpenMP project which declares function prototypes and typedefs used in OMPD. This patch also addressed all feedback. 2020-06-12 Tony Sim libgomp/ChangeLog: * Makefile.am: Added new header. * Makefile.in: Regenerate. * omp-too

[PATCH] libgomp: added partial omp-tools.h for OMPD

2020-06-12 Thread y2s1982 via Gcc-patches
This patch adds partial omp-tools.h continaing OMPD-specific functions and data types. 2020-06-12 Tony Sim libgomp/ChangeLog: * omp-tools.h: New file --- libgomp/omp-tools.h | 278 1 file changed, 278 insertions(+) create mode 100644 lib