Page MenuHomePhabricator

stuart (Stuart Brady)
GPU Compiler Engineer at ARM

Projects

User does not belong to any projects.

User Details

User Since
Apr 20 2018, 6:55 AM (219 w, 4 d)

Recent Activity

May 12 2022

stuart updated the summary of D124256: [OpenCL] Add cl_khr_subgroup_rotate builtins.
May 12 2022, 10:53 AM · Restricted Project, Restricted Project

Dec 16 2021

stuart committed rGceb80557e523: [OpenCL] Add pure attribute to vload builtins (authored by stuart).
[OpenCL] Add pure attribute to vload builtins
Dec 16 2021, 10:31 AM
stuart closed D110742: [OpenCL] Add pure attributes to vload builtins.
Dec 16 2021, 10:31 AM · Restricted Project
stuart updated the diff for D110742: [OpenCL] Add pure attributes to vload builtins.

I've updated the review to include test changes that are required for check-clang-semaopencl to pass.

Dec 16 2021, 7:33 AM · Restricted Project
stuart reopened D110742: [OpenCL] Add pure attributes to vload builtins.
Dec 16 2021, 7:18 AM · Restricted Project
stuart added a reverting change for rG1a376bc28535: [OpenCL] Add pure attribute to vload builtins: rG5aefb1dc1eab: Revert "[OpenCL] Add pure attribute to vload builtins".
Dec 16 2021, 7:17 AM
stuart committed rG5aefb1dc1eab: Revert "[OpenCL] Add pure attribute to vload builtins" (authored by stuart).
Revert "[OpenCL] Add pure attribute to vload builtins"
Dec 16 2021, 7:17 AM
stuart added a reverting change for D110742: [OpenCL] Add pure attributes to vload builtins: rG5aefb1dc1eab: Revert "[OpenCL] Add pure attribute to vload builtins".
Dec 16 2021, 7:17 AM · Restricted Project
stuart committed rG1a376bc28535: [OpenCL] Add pure attribute to vload builtins (authored by stuart).
[OpenCL] Add pure attribute to vload builtins
Dec 16 2021, 6:56 AM
stuart closed D110742: [OpenCL] Add pure attributes to vload builtins.
Dec 16 2021, 6:55 AM · Restricted Project
stuart added a comment to D110742: [OpenCL] Add pure attributes to vload builtins.

Apologies for the late reply... I'd prefer to get the langref updated first, for the sake of consistency and to ensure other stakeholders agree with the interpretation. You can still go ahead with the __attribute__((pure)) changes of course.

Dec 16 2021, 3:16 AM · Restricted Project

Dec 15 2021

stuart updated the diff for D110742: [OpenCL] Add pure attributes to vload builtins.
Dec 15 2021, 8:26 AM · Restricted Project

Oct 8 2021

stuart added a comment to D110742: [OpenCL] Add pure attributes to vload builtins.

For the constant address space, the const attribute (or readnone) can be used. As memory in the constant address space is immutable, the statement in the langref that: "if a readnone function reads or writes memory visible to the program, or has other side-effects, the behavior is undefined" does not apply. The reading of immutable memory does not have side-effects, nor can it be affected by side-effects.

I think readnone might be too strong, because the pointer argument will still be dereferenced (while readnone implies that "the function computes its result [...] based strictly on its arguments, without dereferencing any pointer arguments").

Oct 8 2021, 3:46 AM · Restricted Project

Sep 29 2021

stuart requested review of D110742: [OpenCL] Add pure attributes to vload builtins.
Sep 29 2021, 11:08 AM · Restricted Project
stuart committed rG26db178cc2b3: [OpenCL][NFC] Refactor vloada_half and vstorea_half decls (authored by stuart).
[OpenCL][NFC] Refactor vloada_half and vstorea_half decls
Sep 29 2021, 9:24 AM
stuart closed D110636: [OpenCL][NFC] Refactor vloada_half and vstorea_half decls.
Sep 29 2021, 9:23 AM · Restricted Project

Sep 28 2021

stuart requested review of D110636: [OpenCL][NFC] Refactor vloada_half and vstorea_half decls.
Sep 28 2021, 9:14 AM · Restricted Project

Sep 2 2021

stuart committed rG32955be6bf7d: [OpenCL] Remove decls for scalar vloada_half and vstorea_half* fns (authored by stuart).
[OpenCL] Remove decls for scalar vloada_half and vstorea_half* fns
Sep 2 2021, 2:09 PM
stuart closed D108761: [OpenCL] Remove decls for scalar vloada_half and vstorea_half* fns.
Sep 2 2021, 2:09 PM · Restricted Project

Aug 26 2021

stuart added a comment to D104858: [OpenCL][ARM] Fix ICE when compiling a kernel.

Unfortunately I cannot look at this in detail right now, but I'll reply quickly for a heads up: The problem was not how to detect kernels, but the ABI/CC mismatch to the clSetKerneArg() with (user facing) arguments that get split to multiple args or vice versa. E.g. x86 ABI had a CC where 2xfloat gets to 1xdouble in the generated function finger print, thus there was no 1:1 match of the kernel arguments to the OpenCL-facing ones (making clSetKernelArg calls difficult to implement robustly).

Aug 26 2021, 1:33 PM
stuart retitled D108761: [OpenCL] Remove decls for scalar vloada_half and vstorea_half* fns from [OpenCL] Remove decls for scalar vloada_half* and vstorea_half* fns to [OpenCL] Remove decls for scalar vloada_half and vstorea_half* fns.
Aug 26 2021, 6:15 AM · Restricted Project
stuart retitled D108761: [OpenCL] Remove decls for scalar vloada_half and vstorea_half* fns from [OpenCL] Remove decls for scalar vloada_half and vstorea_half* fns to [OpenCL] Remove decls for scalar vloada_half* and vstorea_half* fns.
Aug 26 2021, 6:14 AM · Restricted Project
stuart updated the summary of D108761: [OpenCL] Remove decls for scalar vloada_half and vstorea_half* fns.
Aug 26 2021, 6:14 AM · Restricted Project
stuart requested review of D108761: [OpenCL] Remove decls for scalar vloada_half and vstorea_half* fns.
Aug 26 2021, 5:45 AM · Restricted Project

Jul 22 2021

stuart accepted D106434: [OpenCL] Add cl_khr_integer_dot_product.

LGTM, too.

Jul 22 2021, 4:52 AM · Restricted Project

Jul 19 2021

stuart committed rG87039c048c0c: [demangler] Fix demangling of 'half' (authored by stuart).
[demangler] Fix demangling of 'half'
Jul 19 2021, 1:23 PM
stuart closed D103833: [demangler] Fix demangling of 'half'.
Jul 19 2021, 1:23 PM · Restricted Project, Restricted Project
stuart accepted D106267: [OpenCL] Add cl_khr_extended_bit_ops.

This looks good to me.

Jul 19 2021, 7:25 AM · Restricted Project
stuart updated the summary of D103833: [demangler] Fix demangling of 'half'.
Jul 19 2021, 7:04 AM · Restricted Project, Restricted Project
stuart updated the summary of D103833: [demangler] Fix demangling of 'half'.
Jul 19 2021, 7:04 AM · Restricted Project, Restricted Project

Jun 25 2021

stuart added a comment to D103833: [demangler] Fix demangling of 'half'.

If I understand correctly, this needs review from the libc++abi group before I can push it. It's a fairly trivial change. Could someone review this please? (Is there anyone specifically I should add?)

Jun 25 2021, 4:27 AM · Restricted Project, Restricted Project
stuart added a comment to D104118: [OpenCL] Use DW_LANG_OpenCL language tag for OpenCL C.

On reflection, I don't think it makes sense to make use of DW_LANG_C_plus_plus_17 or DW_LANG_C_plus_plus_20 in Clang just yet, as these are generally not supported by other tooling. I am a bit confused by DWARF publishing these tags ahead of time, yet tooling having not been updated to recognize them. Regardless, it is clear that support in debuggers needs to come first, which is something that I am not planning to add.

Jun 25 2021, 4:03 AM · debug-info, Restricted Project
stuart committed rGe47027d091de: [OpenCL] Use DW_LANG_OpenCL language tag for OpenCL C (authored by stuart).
[OpenCL] Use DW_LANG_OpenCL language tag for OpenCL C
Jun 25 2021, 3:51 AM
stuart closed D104118: [OpenCL] Use DW_LANG_OpenCL language tag for OpenCL C.
Jun 25 2021, 3:51 AM · debug-info, Restricted Project

Jun 23 2021

stuart updated the diff for D103833: [demangler] Fix demangling of 'half'.

No chances since last time. Rebased to force a rebuild.

Jun 23 2021, 4:32 PM · Restricted Project, Restricted Project
stuart updated the summary of D104118: [OpenCL] Use DW_LANG_OpenCL language tag for OpenCL C.
Jun 23 2021, 8:16 AM · debug-info, Restricted Project
stuart updated the summary of D104118: [OpenCL] Use DW_LANG_OpenCL language tag for OpenCL C.
Jun 23 2021, 8:16 AM · debug-info, Restricted Project
stuart updated the diff for D104118: [OpenCL] Use DW_LANG_OpenCL language tag for OpenCL C.

Added handling of -gstrict-dwarf and updated tests accordingly.

Jun 23 2021, 8:15 AM · debug-info, Restricted Project

Jun 16 2021

stuart added a comment to D104291: [Debug-Info] strict dwarf for DW_LANG_C_plus_plus_14.

There is no CPlusPlus03 in LangOptions, so it is better not to merge DW_LANG_C_plus_plus_03 support with D99250.

Jun 16 2021, 3:38 AM · Restricted Project, debug-info

Jun 15 2021

stuart planned changes to D104118: [OpenCL] Use DW_LANG_OpenCL language tag for OpenCL C.

Changes will be required to align this with D104291.

Jun 15 2021, 7:45 AM · debug-info, Restricted Project
stuart accepted D104291: [Debug-Info] strict dwarf for DW_LANG_C_plus_plus_14.
Jun 15 2021, 7:37 AM · Restricted Project, debug-info
stuart added a comment to D104291: [Debug-Info] strict dwarf for DW_LANG_C_plus_plus_14.

This looks good to me.

Jun 15 2021, 7:37 AM · Restricted Project, debug-info
stuart added inline comments to D104118: [OpenCL] Use DW_LANG_OpenCL language tag for OpenCL C.
Jun 15 2021, 7:26 AM · debug-info, Restricted Project
stuart added inline comments to D104118: [OpenCL] Use DW_LANG_OpenCL language tag for OpenCL C.
Jun 15 2021, 2:59 AM · debug-info, Restricted Project

Jun 11 2021

stuart updated the diff for D104118: [OpenCL] Use DW_LANG_OpenCL language tag for OpenCL C.

Add missing trailing commas to CHECK lines of FileCheck test.

Jun 11 2021, 8:10 AM · debug-info, Restricted Project
stuart added a comment to D104118: [OpenCL] Use DW_LANG_OpenCL language tag for OpenCL C.

Note: there is currently no DWARF language code defined for C++ for OpenCL, so we must use DW_LANG_C_plus_plus* if we wish to be able to determine whether output has been generated from C++ for OpenCL source or from OpenCL C source. I have raised DWARF issue 210514.1 to add a dedicated C++ for OpenCL code in the next version of DWARF, but for now I believe that it is best to use DW_LANG_OpenCL for OpenCL C only, and not for C++ for OpenCL.

Jun 11 2021, 7:32 AM · debug-info, Restricted Project
stuart requested review of D104118: [OpenCL] Use DW_LANG_OpenCL language tag for OpenCL C.
Jun 11 2021, 7:21 AM · debug-info, Restricted Project

Jun 10 2021

stuart updated the summary of D103833: [demangler] Fix demangling of 'half'.
Jun 10 2021, 12:39 PM · Restricted Project, Restricted Project
stuart added a comment to D103833: [demangler] Fix demangling of 'half'.

(I note the new behavior also matches gcc)

Jun 10 2021, 12:39 PM · Restricted Project, Restricted Project
stuart updated subscribers of D103833: [demangler] Fix demangling of 'half'.
Jun 10 2021, 6:46 AM · Restricted Project, Restricted Project
stuart added a comment to D103833: [demangler] Fix demangling of 'half'.

but your diff excerpt in the comment above is missing that extra directory prefix. I suspect you've got a local configuration file setting diff.noprefix = true

Jun 10 2021, 6:31 AM · Restricted Project, Restricted Project
stuart updated the diff for D103833: [demangler] Fix demangling of 'half'.

Add a/ and b/ prefixes to diff.

Jun 10 2021, 6:23 AM · Restricted Project, Restricted Project
stuart added a comment to D103833: [demangler] Fix demangling of 'half'.
Jun 10 2021, 3:47 AM · Restricted Project, Restricted Project
stuart updated the diff for D103833: [demangler] Fix demangling of 'half'.

Reupload with no changes.

Jun 10 2021, 3:45 AM · Restricted Project, Restricted Project
stuart updated subscribers of D103833: [demangler] Fix demangling of 'half'.

@jyknight, I have reuploaded the exact same diff with full context:

Jun 10 2021, 3:18 AM · Restricted Project, Restricted Project
stuart updated the diff for D103833: [demangler] Fix demangling of 'half'.

Reupload with no changes.

Jun 10 2021, 2:59 AM · Restricted Project, Restricted Project

Jun 7 2021

stuart added a comment to D103833: [demangler] Fix demangling of 'half'.

The pre-merge check failures relating to the failure to include "ItaniumDemangle.h" seem confusing to me. I cannot see how they would be caused by this change, itself: this looks on the surface to be a problem with the CI. Do I need to do anything about this?

Jun 7 2021, 2:03 PM · Restricted Project, Restricted Project
stuart added a comment to D103833: [demangler] Fix demangling of 'half'.
Jun 7 2021, 1:44 PM · Restricted Project, Restricted Project
stuart updated the summary of D103833: [demangler] Fix demangling of 'half'.
Jun 7 2021, 1:42 PM · Restricted Project, Restricted Project
stuart updated the diff for D103833: [demangler] Fix demangling of 'half'.
Jun 7 2021, 1:42 PM · Restricted Project, Restricted Project
stuart added reviewers for D103833: [demangler] Fix demangling of 'half': jyknight, erik.pilkington.
Jun 7 2021, 11:44 AM · Restricted Project, Restricted Project
stuart requested review of D103833: [demangler] Fix demangling of 'half'.
Jun 7 2021, 11:39 AM · Restricted Project, Restricted Project
stuart committed rG9b14670f3ca2: [OpenCL] Add const attribute to ctz() builtins (authored by stuart).
[OpenCL] Add const attribute to ctz() builtins
Jun 7 2021, 3:44 AM
stuart closed D97725: [OpenCL] Add const attribute to ctz() builtin.
Jun 7 2021, 3:44 AM · Restricted Project, Restricted Project

Jun 4 2021

stuart committed rG333987b04589: [OpenCL] Add DWARF address spaces mapping for SPIR (authored by jzzheng22).
[OpenCL] Add DWARF address spaces mapping for SPIR
Jun 4 2021, 10:11 AM
stuart closed D103097: Add DWARF address spaces mapping for SPIR.
Jun 4 2021, 10:11 AM · Restricted Project
stuart added inline comments to D103097: Add DWARF address spaces mapping for SPIR.
Jun 4 2021, 8:44 AM · Restricted Project
stuart committed rG86c24493ea66: [OpenCL][NFC] Test commit: tidy up whitespace in comment (authored by stuart).
[OpenCL][NFC] Test commit: tidy up whitespace in comment
Jun 4 2021, 6:45 AM

Mar 11 2021

stuart accepted D98418: [OpenCL] Remove mixed signedness atomic_fetch_ from opencl-c.h.

Looks good to me.

Mar 11 2021, 4:18 PM · Restricted Project

Mar 1 2021

stuart requested review of D97725: [OpenCL] Add const attribute to ctz() builtin.
Mar 1 2021, 1:26 PM · Restricted Project, Restricted Project

Feb 9 2021

stuart requested changes to D96161: [OpenCL] Fix printing of types with signed prefix in arg info metadata.

Looks good, just some suggestions about the test.

Feb 9 2021, 3:07 AM · Restricted Project

Feb 5 2021

stuart requested changes to D96161: [OpenCL] Fix printing of types with signed prefix in arg info metadata.

Looks good. Small nit about the test case.

Feb 5 2021, 11:34 AM · Restricted Project
stuart added a comment to D96151: [OpenCL] Fix pipe type printing in arg info metadata.

This looks like a really good cleanup, in addition to fixing the metadata for pipes.

Feb 5 2021, 11:18 AM · Restricted Project

Sep 12 2019

stuart added inline comments to D67507: Refer to IEEE 754-2019 in langref instead of 2018 draft.
Sep 12 2019, 11:21 AM · Restricted Project
stuart added inline comments to D67507: Refer to IEEE 754-2019 in langref instead of 2018 draft.
Sep 12 2019, 10:51 AM · Restricted Project
stuart added a comment to D67507: Refer to IEEE 754-2019 in langref instead of 2018 draft.

@hans, is it too late for this to be considered as a candidate for the 9.0.0 release?

Sep 12 2019, 9:49 AM · Restricted Project
stuart created D67507: Refer to IEEE 754-2019 in langref instead of 2018 draft.
Sep 12 2019, 9:42 AM · Restricted Project

Apr 27 2018

stuart updated the summary of D46015: [OpenCL] Add separate read_only and write_only pipe IR types.
Apr 27 2018, 3:37 AM
stuart updated the summary of D46015: [OpenCL] Add separate read_only and write_only pipe IR types.
Apr 27 2018, 3:33 AM
stuart updated the summary of D46015: [OpenCL] Add separate read_only and write_only pipe IR types.
Apr 27 2018, 3:31 AM

Apr 25 2018

stuart added a comment to D46015: [OpenCL] Add separate read_only and write_only pipe IR types.

There should not be need for bitcast. Could give an example ? Thanks.

If I have a write_only pipe as the argument to get_pipe_max_packets(), and this uses a single __get_pipe_num_packets() function taking a read_only pipe, we will automatically get a bitcast:

%20 = call i32 bitcast (i32 (%opencl.pipe_ro_t*, i32, i32)* @__get_pipe_max_packets to i32 (%opencl.pipe_wo_t*, i32, i32)*)(%opencl.pipe_wo_t* %19, i32 4, i32 4)

Sorry, but I don't quite understand what does get_pipe_max_packets(), uses __get_pipe_num_packets() mean. Could you clarify? Possibly OpenCL C source example could help.

Apr 25 2018, 9:51 AM
stuart added a comment to D46015: [OpenCL] Add separate read_only and write_only pipe IR types.

There should not be need for bitcast. Could give an example ? Thanks.

Apr 25 2018, 8:31 AM
stuart added a comment to D46015: [OpenCL] Add separate read_only and write_only pipe IR types.

It is not clear why we need two versions of get_pipe_num_packets and get_pipe_max_packets builtins. There is only one instruction per builtin in the SPIR-V spec. I think splitting the IR type is enough for translation to SPIR-V purposes.

Apr 25 2018, 8:25 AM
stuart updated the diff for D46015: [OpenCL] Add separate read_only and write_only pipe IR types.

Changed new getPipeType() method to have protected visibility.

Apr 25 2018, 8:16 AM

Apr 24 2018

stuart created D46015: [OpenCL] Add separate read_only and write_only pipe IR types.
Apr 24 2018, 8:25 AM