Page MenuHomePhabricator

arichardson (Alexander Richardson)
User

Projects

User does not belong to any projects.

User Details

User Since
Sep 4 2015, 4:18 PM (281 w, 1 d)

Recent Activity

Yesterday

arichardson added a comment to D95240: [update_llc_test_checks] Support AVR.

It might be worth adding a test in llvm/test/tools/UpdateTestChecks/update_llc_test_checks/ but I'd say that's not essential to land this patch.

Fri, Jan 22, 8:22 AM · Restricted Project
arichardson updated subscribers of D95137: [update_(llc_)test_checks.py] Support pre-processing commands.
Fri, Jan 22, 2:55 AM · Restricted Project
arichardson published D95137: [update_(llc_)test_checks.py] Support pre-processing commands for review.
Fri, Jan 22, 2:42 AM · Restricted Project
arichardson updated the summary of D95142: [SLC] Simplify strcpy and friends with non-zero address spaces.
Fri, Jan 22, 2:01 AM · Restricted Project
arichardson updated the diff for D95142: [SLC] Simplify strcpy and friends with non-zero address spaces.

Use isPointerType() instead.

Fri, Jan 22, 2:00 AM · Restricted Project

Thu, Jan 21

arichardson added a comment to D91256: [AtomicExpandPass] Allow for pointer types in insertRMWCmpXchgLoop().

ping?

Thu, Jan 21, 8:42 AM · Restricted Project
arichardson added inline comments to D95142: [SLC] Simplify strcpy and friends with non-zero address spaces.
Thu, Jan 21, 8:41 AM · Restricted Project
arichardson added inline comments to D95142: [SLC] Simplify strcpy and friends with non-zero address spaces.
Thu, Jan 21, 8:17 AM · Restricted Project
arichardson added a reviewer for D95142: [SLC] Simplify strcpy and friends with non-zero address spaces: jrtc27.
Thu, Jan 21, 8:12 AM · Restricted Project
arichardson requested review of D95142: [SLC] Simplify strcpy and friends with non-zero address spaces.
Thu, Jan 21, 8:09 AM · Restricted Project

Wed, Jan 20

arichardson committed rTc84b15fc6f84: Link libm in the complex-5.c testcase (authored by arichardson).
Link libm in the complex-5.c testcase
Wed, Jan 20, 7:53 AM
arichardson closed D89621: Link libm in the complex-5.c testcase.
Wed, Jan 20, 7:53 AM
arichardson changed the repository for D89621: Link libm in the complex-5.c testcase from rOLDT svn-test-suite to rT test-suite.
Wed, Jan 20, 7:53 AM
arichardson committed rG537d90db827d: [libc++] Split re.alg tests into locale-dependent and independent tests (authored by arichardson).
[libc++] Split re.alg tests into locale-dependent and independent tests
Wed, Jan 20, 7:49 AM
arichardson closed D94969: [libc++] Split re.alg tests into locale-dependent and independent tests.
Wed, Jan 20, 7:49 AM · Restricted Project
arichardson requested review of D95050: Make Value::MaxAlignment(Exponent) constexpr.
Wed, Jan 20, 7:48 AM · Restricted Project

Tue, Jan 19

arichardson committed rG077a84f91140: [libc++] Sync TEST_HAS_TIMESPEC_GET and _LIBCPP_HAS_TIMESPEC_GET on FreeBSD (authored by arichardson).
[libc++] Sync TEST_HAS_TIMESPEC_GET and _LIBCPP_HAS_TIMESPEC_GET on FreeBSD
Tue, Jan 19, 7:05 AM
arichardson closed D94292: [libc++] Sync TEST_HAS_TIMESPEC_GET and _LIBCPP_HAS_TIMESPEC_GET on FreeBSD.
Tue, Jan 19, 7:04 AM · Restricted Project
arichardson requested review of D94969: [libc++] Split re.alg tests into locale-dependent and independent tests.
Tue, Jan 19, 6:47 AM · Restricted Project
arichardson requested review of D94963: [compiler-rt] Silence a deprecation warning on FreeBSD.
Tue, Jan 19, 4:59 AM · Restricted Project

Tue, Jan 12

arichardson accepted D94491: [llvm] [cmake] Remove obsolete /usr/local hack for *BSD.
Tue, Jan 12, 9:28 AM · Restricted Project
arichardson added a comment to D94491: [llvm] [cmake] Remove obsolete /usr/local hack for *BSD.

I can confirm that it builds fine without that block and that there are no changes in CMakeCache.txt.

Tue, Jan 12, 5:59 AM · Restricted Project
arichardson added a comment to D94491: [llvm] [cmake] Remove obsolete /usr/local hack for *BSD.

What happens if you just drop this block unconditionally?

Tue, Jan 12, 5:00 AM · Restricted Project

Fri, Jan 8

arichardson committed rG32733c347d7b: [libc++] Add missing XFAIL to tests that need __atomic_* libcalls (authored by arichardson).
[libc++] Add missing XFAIL to tests that need __atomic_* libcalls
Fri, Jan 8, 4:49 AM
arichardson committed rG00530dee5d12: [compiler-rt] Implement __atomic_is_lock_free (authored by arichardson).
[compiler-rt] Implement __atomic_is_lock_free
Fri, Jan 8, 4:49 AM
arichardson closed D88818: [libc++] Add missing XFAIL to tests that need __atomic_* libcalls.
Fri, Jan 8, 4:49 AM · Restricted Project
arichardson closed D92302: [compiler-rt] Implement __atomic_is_lock_free.
Fri, Jan 8, 4:49 AM · Restricted Project
arichardson requested review of D94292: [libc++] Sync TEST_HAS_TIMESPEC_GET and _LIBCPP_HAS_TIMESPEC_GET on FreeBSD.
Fri, Jan 8, 3:45 AM · Restricted Project
arichardson added inline comments to D91154: [libc++] Guard __cpp_lib_constexpr_dynamic_alloc with compiler support.
Fri, Jan 8, 3:31 AM · Restricted Project
arichardson updated the diff for D91154: [libc++] Guard __cpp_lib_constexpr_dynamic_alloc with compiler support.

rebase

Fri, Jan 8, 3:31 AM · Restricted Project

Thu, Jan 7

arichardson added a comment to D89621: Link libm in the complex-5.c testcase.

Will commit this next week unless there are any objections.

Thu, Jan 7, 5:32 AM
arichardson added a comment to D91256: [AtomicExpandPass] Allow for pointer types in insertRMWCmpXchgLoop().

ping?

Thu, Jan 7, 5:31 AM · Restricted Project
arichardson added a comment to D92302: [compiler-rt] Implement __atomic_is_lock_free.

ping?

Thu, Jan 7, 5:31 AM · Restricted Project

Dec 22 2020

arichardson committed rG6277bd75dc71: [compiler-rt] Fix atomic_test.c on macOS (authored by arichardson).
[compiler-rt] Fix atomic_test.c on macOS
Dec 22 2020, 3:58 AM
arichardson committed rG0f81598cc1f4: [libc++] Add a 'is-lockfree-runtime-function' lit feature (authored by arichardson).
[libc++] Add a 'is-lockfree-runtime-function' lit feature
Dec 22 2020, 3:58 AM
arichardson closed D92833: [compiler-rt] Fix atomic_test.c on macOS.
Dec 22 2020, 3:58 AM · Restricted Project
arichardson closed D91911: [libc++] Add a 'is-lockfree-runtime-function' lit feature.
Dec 22 2020, 3:58 AM · Restricted Project
arichardson added a comment to D88818: [libc++] Add missing XFAIL to tests that need __atomic_* libcalls.

Will commit this once D92302 has landed.

Dec 22 2020, 3:41 AM · Restricted Project
arichardson added a comment to D92302: [compiler-rt] Implement __atomic_is_lock_free.

@ldionne Test has been added, is this okay to commit now?

Dec 22 2020, 3:37 AM · Restricted Project

Dec 11 2020

arichardson added a comment to D92302: [compiler-rt] Implement __atomic_is_lock_free.

Do we need change __atomic_is_lock_free to return false for 16 byte atomics on x86 if clang generates incorrect code?

I believe compiler-rt should be consistent with the code that Clang generates, even if Clang generates sub-optimal code. Then, we can fix compiler-rt at the same time as we fix Clang. Otherwise, it seems like one could say that we have two bugs: one is the fact that Clang doesn't implement 16 bytes atomics without locks, and the other one is that compiler-rt lies, by pretending that we do.

Dec 11 2020, 11:42 AM · Restricted Project
arichardson accepted D93033: [llvm-readobj] - For SHT_REL relocations, don't display an addend..

My only concern about removing the 0x0 from the CHECK lines is that these tests will still pass if we do add support for reading REL addends. I see that many of the tests now contain {{$}}, maybe add this for all of them?

I've updated those that are related to llvm-readobj (i.e. tests from test/tools/llvm-readobj). I haven't updated others because they are not testing llvm-readobj output or relocation addend values (they were always 0x0 previously,
what is simply wrong technically). Given that I feel that spreading of {{$}} past the test/tools/llvm-readobj folder is perhaps a bit excessive.

Dec 11 2020, 9:12 AM · Restricted Project

Dec 10 2020

arichardson added a comment to D93033: [llvm-readobj] - For SHT_REL relocations, don't display an addend..

Thanks, this is a lot less confusing that printing 0. Ideally, we'd read the REL addend from the offset, but that's obviously a lot more effort.

Dec 10 2020, 7:13 AM · Restricted Project

Dec 8 2020

arichardson added a comment to D92832: [compiler-rt] Allow atomic_test to pass on x86_64.

It appears that GCC changed its behaviour from cmpxchg to calling the helper function for GCC 7: https://godbolt.org/z/s9fxfY

Dec 8 2020, 5:40 AM · Restricted Project
arichardson updated subscribers of D92302: [compiler-rt] Implement __atomic_is_lock_free.
Dec 8 2020, 4:53 AM · Restricted Project
arichardson updated the diff for D92302: [compiler-rt] Implement __atomic_is_lock_free.
  • Add a test case (passes on x86_64 macOS, not tried other architectures yet)
  • Rebased on top of D92833
Dec 8 2020, 4:44 AM · Restricted Project
arichardson requested review of D92833: [compiler-rt] Fix atomic_test.c on macOS.
Dec 8 2020, 4:19 AM · Restricted Project
arichardson requested review of D92832: [compiler-rt] Allow atomic_test to pass on x86_64.
Dec 8 2020, 4:18 AM · Restricted Project
arichardson added inline comments to D85044: Add __atomic_is_lock_free to compiler-rt.
Dec 8 2020, 3:06 AM · Restricted Project, Restricted Project
arichardson added a comment to D92302: [compiler-rt] Implement __atomic_is_lock_free.

I just tried adding tests for this, and it turns out the existing atomic_test.c crashes due to __c11_atomic_load being implemented with cmpxchg16b. This crashes if the source is in read-only memory (as happens with this test). Do we need change __atomic_is_lock_free to return false for 16 byte atomics on x86 if clang generates incorrect code?

Dec 8 2020, 3:04 AM · Restricted Project

Dec 1 2020

arichardson planned changes to D92302: [compiler-rt] Implement __atomic_is_lock_free.

Will add tests for this in the coming days.

Dec 1 2020, 8:28 AM · Restricted Project
arichardson added a comment to D88818: [libc++] Add missing XFAIL to tests that need __atomic_* libcalls.

This technically regresses our coverage of atomics on Apple platforms, since those tests are testing both small and large types. I'm OK with that, but I'll make it a priority to investigate shipping support for non-lockfree atomics on Apple platforms.

Dec 1 2020, 8:27 AM · Restricted Project
arichardson added a comment to D91911: [libc++] Add a 'is-lockfree-runtime-function' lit feature.

Thanks for reviewing!

Dec 1 2020, 8:25 AM · Restricted Project

Nov 30 2020

arichardson added a comment to D91256: [AtomicExpandPass] Allow for pointer types in insertRMWCmpXchgLoop().

ping?

Nov 30 2020, 1:46 AM · Restricted Project
arichardson added a comment to D91911: [libc++] Add a 'is-lockfree-runtime-function' lit feature.

How difficult would it be to implement __atomic_is_lock_free in compiler-rt? I think something like this in atomic.c would work:

int __atomic_is_lock_free(size_t size, void const volatile* ptr) {
#define LOCK_FREE_ACTION(type) return sizeof(type) <= size;
  LOCK_FREE_CASES(ptr);
#undef LOCK_FREE_ACTION
  return 0;
}

However, I'm not familiar with how to add builtins in compiler-rt, and I haven't been able to figure out the details at a glance.

Do I understand correctly that:

  1. When Clang sees __atomic_is_lock_free(args...), it tries to generate code directly for it if it can.
  2. Otherwise, it generates an external call to a function called int __atomic_is_lock_free(unsigned long, void const volatile*);
  3. If a library that defines this function isn't provided, a linker error follows

Is that how these work? We can definitely add a workaround to fix the test suite here, however I'd also like to actually solve the root cause of this issue. It's also something we've had requests about in the past.

Nov 30 2020, 1:41 AM · Restricted Project
arichardson requested review of D92302: [compiler-rt] Implement __atomic_is_lock_free.
Nov 30 2020, 1:39 AM · Restricted Project

Nov 29 2020

arichardson updated the diff for D48803: Place the BlockAddress type in the address space of the containing function.
  • Update langref
Nov 29 2020, 5:13 AM · Restricted Project
arichardson retitled D48803: Place the BlockAddress type in the address space of the containing function from Place the BlockAddress type in the program address space to Place the BlockAddress type in the address space of the containing function.
Nov 29 2020, 5:05 AM · Restricted Project
arichardson updated the diff for D48803: Place the BlockAddress type in the address space of the containing function.
  • Restore Constants.cpp change that was accidentally dropped while updating this revision
Nov 29 2020, 5:05 AM · Restricted Project

Nov 27 2020

arichardson added a comment to D88818: [libc++] Add missing XFAIL to tests that need __atomic_* libcalls.

CI seems happy now. Does this + D91911 look reasonable @ldionne?

Nov 27 2020, 10:59 AM · Restricted Project
arichardson updated the diff for D91154: [libc++] Guard __cpp_lib_constexpr_dynamic_alloc with compiler support.
  • update the script instead
Nov 27 2020, 10:58 AM · Restricted Project
arichardson updated the diff for D48803: Place the BlockAddress type in the address space of the containing function.
  • Make use of per-function state and add various tests
Nov 27 2020, 10:45 AM · Restricted Project

Nov 26 2020

arichardson added a comment to D92190: [libc++] fix std::sort(T**, T**).

Oh, and I agree with Marshall -- if there's a bug report for this, please link it from the test and mention it in the commit message.

Nov 26 2020, 10:47 AM · Restricted Project
arichardson added a comment to D92190: [libc++] fix std::sort(T**, T**).

This is required for CHERI, where we use 128-bit pointers (well actually 129 bits, since we also have a hidden validity bit).
For us size_t/ptrdiff_t are still 64 bits, but uintptr_t is 128-bits, so we need to do this sort using uintptr_t.

Nov 26 2020, 9:57 AM · Restricted Project
arichardson committed rG0b20d0af3f0a: [libc++] Fix two fr_FR locale tests on FreeBSD (authored by arichardson).
[libc++] Fix two fr_FR locale tests on FreeBSD
Nov 26 2020, 8:11 AM
arichardson closed D91165: [libc++] Fix two fr_FR locale tests on FreeBSD.
Nov 26 2020, 8:11 AM · Restricted Project
arichardson updated the diff for D91911: [libc++] Add a 'is-lockfree-runtime-function' lit feature.

rebase after formatting change

Nov 26 2020, 6:52 AM · Restricted Project

Nov 25 2020

arichardson updated the summary of D91911: [libc++] Add a 'is-lockfree-runtime-function' lit feature.
Nov 25 2020, 6:31 AM · Restricted Project
arichardson updated the diff for D88818: [libc++] Add missing XFAIL to tests that need __atomic_* libcalls.

Rebase for CI

Nov 25 2020, 6:29 AM · Restricted Project
arichardson updated the diff for D91911: [libc++] Add a 'is-lockfree-runtime-function' lit feature.

Correctly skip align.pass.pass.cpp for macOS

Nov 25 2020, 3:40 AM · Restricted Project

Nov 23 2020

arichardson added a comment to D88252: z_Linux_asm.S modifications for arm64 (AARCH64) for Darwin/macOS.

This seems fine, but the patch should be uploaded against the monorepo so that it shows up as openmp/runtime/src/z_Linux_asm.S.

Nov 23 2020, 12:36 PM · Restricted Project, Restricted Project
arichardson added a comment to D91428: Add support for multiple program address spaces.

The change to rename getProgramAddressSpace getDefaultProgramAddressSpace seems fine to me since it matches the GlobalsAddressSpace.

Nov 23 2020, 12:12 PM · Restricted Project, Restricted Project
arichardson requested changes to D91428: Add support for multiple program address spaces.

I don't see why you would need multiple program address spaces to support calls to other address spaces. You can already do the following:

define i32 @foo(i32) addrspace(1) {
    %ret = add i32 %0, 1
    ret i32 %ret
}
Nov 23 2020, 12:08 PM · Restricted Project, Restricted Project

Nov 21 2020

arichardson updated the summary of D88818: [libc++] Add missing XFAIL to tests that need __atomic_* libcalls.
Nov 21 2020, 4:40 AM · Restricted Project
arichardson updated the diff for D88818: [libc++] Add missing XFAIL to tests that need __atomic_* libcalls.

Rebase on top of D91911 and remove the #ifndef APPLE special case from atomic_helpers.

Nov 21 2020, 4:39 AM · Restricted Project
arichardson requested review of D91911: [libc++] Add a 'is-lockfree-runtime-function' lit feature.
Nov 21 2020, 4:33 AM · Restricted Project

Nov 20 2020

arichardson added a comment to D91154: [libc++] Guard __cpp_lib_constexpr_dynamic_alloc with compiler support.

Thanks for looking into this. I just recently hacked up something to silence these failures on the Clang 8 builders, but I think this is better.

However, the tests like libcxx/test/std/language.support/support.limits/support.limits.general/memory.version.pass.cpp are auto-generated. You need to modify libcxx/utils/generate_feature_test_macro_components.py instead.

Nov 20 2020, 12:58 PM · Restricted Project
arichardson added a comment to D70947: Add a default address space for globals to DataLayout.

Why is this useful rather than having targets set the address space used in the backend explicitly? i.e. how is what amdgpu was doing up to this point not ok? It's not really clear here.

Nov 20 2020, 12:44 PM · Restricted Project
arichardson committed rG51e09e1d5aa4: [AMDGPU] Set the default globals address space to 1 (authored by arichardson).
[AMDGPU] Set the default globals address space to 1
Nov 20 2020, 7:47 AM
arichardson committed rG3bc4157556b0: Add a default address space for globals to DataLayout (authored by arichardson).
Add a default address space for globals to DataLayout
Nov 20 2020, 7:47 AM
arichardson closed D84345: [AMDGPU] Set the default globals address space to 1.
Nov 20 2020, 7:47 AM · Restricted Project, Restricted Project
arichardson closed D70947: Add a default address space for globals to DataLayout.
Nov 20 2020, 7:47 AM · Restricted Project

Nov 19 2020

arichardson added inline comments to D17993: [CodeGen] Apply 'nonnull' and 'dereferenceable(N)' to 'this' pointer arguments..
Nov 19 2020, 3:32 AM · Restricted Project, Restricted Project

Nov 18 2020

arichardson added inline comments to D17993: [CodeGen] Apply 'nonnull' and 'dereferenceable(N)' to 'this' pointer arguments..
Nov 18 2020, 4:12 AM · Restricted Project, Restricted Project

Nov 17 2020

arichardson added inline comments to D17993: [CodeGen] Apply 'nonnull' and 'dereferenceable(N)' to 'this' pointer arguments..
Nov 17 2020, 2:51 PM · Restricted Project, Restricted Project

Nov 14 2020

arichardson added inline comments to D89239: [RISCV][PrologEpilogInserter] "Float" emergency spill slots to avoid making them immediately unreachable from the stack pointer.
Nov 14 2020, 6:14 AM · Restricted Project

Nov 13 2020

arichardson added inline comments to D89239: [RISCV][PrologEpilogInserter] "Float" emergency spill slots to avoid making them immediately unreachable from the stack pointer.
Nov 13 2020, 5:14 AM · Restricted Project

Nov 12 2020

arichardson added inline comments to D89239: [RISCV][PrologEpilogInserter] "Float" emergency spill slots to avoid making them immediately unreachable from the stack pointer.
Nov 12 2020, 2:53 PM · Restricted Project

Nov 11 2020

arichardson committed rGfb9942f87628: [AsmParser] Add source location to all errors related to .cfi directives (authored by arichardson).
[AsmParser] Add source location to all errors related to .cfi directives
Nov 11 2020, 9:01 AM
arichardson closed D89787: [AsmParser] Add source location to all errors related to .cfi directives.
Nov 11 2020, 9:01 AM · Restricted Project
arichardson requested review of D91256: [AtomicExpandPass] Allow for pointer types in insertRMWCmpXchgLoop().
Nov 11 2020, 6:28 AM · Restricted Project

Nov 10 2020

arichardson added a comment to D91165: [libc++] Fix two fr_FR locale tests on FreeBSD.

This is fine with me; have we always done that?

Nov 10 2020, 8:48 AM · Restricted Project
arichardson requested review of D91165: [libc++] Fix two fr_FR locale tests on FreeBSD.
Nov 10 2020, 7:40 AM · Restricted Project
arichardson updated the diff for D91154: [libc++] Guard __cpp_lib_constexpr_dynamic_alloc with compiler support.
Nov 10 2020, 5:46 AM · Restricted Project
arichardson requested review of D91154: [libc++] Guard __cpp_lib_constexpr_dynamic_alloc with compiler support.
Nov 10 2020, 5:44 AM · Restricted Project
arichardson retitled D88818: [libc++] Add missing XFAIL to tests that need __atomic_* libcalls from [libc++][FreeBSD] XFAIL tests that need __atomic_* libcalls on older versions to [libc++] Add missing XFAIL to tests that need __atomic_* libcalls.
Nov 10 2020, 4:53 AM · Restricted Project
arichardson updated the diff for D88818: [libc++] Add missing XFAIL to tests that need __atomic_* libcalls.

Use non-lockfree-atomics instead.

Nov 10 2020, 4:52 AM · Restricted Project
arichardson added a comment to D70947: Add a default address space for globals to DataLayout.

@dylanmckay D84345 is now accepted, is this good to land now?

Nov 10 2020, 4:47 AM · Restricted Project
arichardson planned changes to D88818: [libc++] Add missing XFAIL to tests that need __atomic_* libcalls.

Will update to use non-lockfree-atomics

Nov 10 2020, 4:45 AM · Restricted Project

Nov 9 2020

arichardson planned changes to D88903: [lit][libcxx] Add a --run-with-debugger/--gdb flag.

needs rebasing.

Nov 9 2020, 11:43 AM · Restricted Project, Restricted Project
arichardson added inline comments to D89495: [libc++] Use the internal Lit shell to run the tests.
Nov 9 2020, 11:32 AM · Restricted Project