Page MenuHomePhabricator

arichardson (Alexander Richardson)
User

Projects

User does not belong to any projects.

User Details

User Since
Sep 4 2015, 4:18 PM (301 w, 20 h)

Recent Activity

Tue, Jun 8

arichardson added inline comments to D103886: [sanitizer] Fix build on FreeBSD RISC-V.
Tue, Jun 8, 5:10 AM · Restricted Project
arichardson requested review of D103886: [sanitizer] Fix build on FreeBSD RISC-V.
Tue, Jun 8, 4:09 AM · Restricted Project
arichardson added inline comments to D99621: [CMake][Compiler-rt] Make it possible to configure standalone compiler-rt without `LLVMConfig.cmake`..
Tue, Jun 8, 4:03 AM · Restricted Project
arichardson requested review of D103876: [builtins] Allow compiling the builtins without libc headers.
Tue, Jun 8, 1:50 AM · Restricted Project

Thu, Jun 3

arichardson committed rG90344499ae76: [lld-macho] Fix BUILD_SHARED_LIBS build (authored by arichardson).
[lld-macho] Fix BUILD_SHARED_LIBS build
Thu, Jun 3, 12:00 PM
arichardson closed D100999: [lld-macho] Fix BUILD_SHARED_LIBS build.
Thu, Jun 3, 12:00 PM · Restricted Project, Restricted Project
arichardson updated the diff for D100999: [lld-macho] Fix BUILD_SHARED_LIBS build.

rebase after macro name change

Thu, Jun 3, 11:58 AM · Restricted Project, Restricted Project
arichardson added a comment to D101451: [ELF] Implement X86_64::getImplicitAddend().

Do you have a branch where I can apply the patch series at once?

Thu, Jun 3, 11:42 AM · Restricted Project
arichardson added a comment to D100999: [lld-macho] Fix BUILD_SHARED_LIBS build.

Sorry, forgot to commit this. Will do so now.

Thu, Jun 3, 11:39 AM · Restricted Project, Restricted Project

Sun, May 30

arichardson added a comment to D48803: Place the BlockAddress type in the address space of the containing function.

I believe all remaining issues were addressed in the latest version.

Sun, May 30, 7:28 AM · Restricted Project

Sat, May 29

arichardson accepted D103346: [Support] Fix getMainExecutable on FreeBSD when called via an absolute path.
Sat, May 29, 12:52 AM · Restricted Project

Apr 28 2021

arichardson updated the diff for D48803: Place the BlockAddress type in the address space of the containing function.
  • Drop check for i8 as suggested by @arsenm
Apr 28 2021, 10:18 AM · Restricted Project
arichardson updated the diff for D100544: [ELF][AArch64] Write addends for TLSDESC relocations with -z rel.

rebase

Apr 28 2021, 9:45 AM · Restricted Project
arichardson added a comment to D101455: [ELF] Implement RISCV::getImplicitAddend().

Honestly this seems rather academic, surely we should just mandate Elf_Rela for RISC-V? I've filed https://github.com/riscv/riscv-elf-psabi-doc/issues/186.

Apr 28 2021, 7:16 AM · Restricted Project
arichardson updated the diff for D100490: [ELF] Refactor DynamicReloc to fix incorrect relocation addends.
  • Add addSymbolReloc() as suggested
Apr 28 2021, 7:04 AM · Restricted Project
arichardson added inline comments to D100490: [ELF] Refactor DynamicReloc to fix incorrect relocation addends.
Apr 28 2021, 7:04 AM · Restricted Project
arichardson requested review of D101455: [ELF] Implement RISCV::getImplicitAddend().
Apr 28 2021, 6:59 AM · Restricted Project
arichardson requested review of D101454: [ELF] Write R_RISCV_IRELATIVE addends with -z rel.
Apr 28 2021, 6:58 AM · Restricted Project
arichardson requested review of D101452: [ELF] Write R_X86_64_IRELATIVE addends with -z rel.
Apr 28 2021, 6:46 AM · Restricted Project
arichardson requested review of D101451: [ELF] Implement X86_64::getImplicitAddend().
Apr 28 2021, 6:39 AM · Restricted Project
arichardson requested review of D101450: [ELF] Check the Elf_Rel addends for dynamic relocations.
Apr 28 2021, 6:38 AM · Restricted Project
arichardson retitled D100490: [ELF] Refactor DynamicReloc to fix incorrect relocation addends from [ELF] Check the Elf_Rel addends for dynamic relocations to [ELF] Refactor DynamicReloc to fix incorrect relocation addends.
Apr 28 2021, 6:31 AM · Restricted Project
arichardson updated the diff for D100490: [ELF] Refactor DynamicReloc to fix incorrect relocation addends.

Split the addend checking into a separate review, this now only include fixes for incorrect addends plus the DynamicReloc refactoring.

Apr 28 2021, 6:25 AM · Restricted Project
arichardson added a comment to D48803: Place the BlockAddress type in the address space of the containing function.

Thanks for the review, will update shortly.

Apr 28 2021, 6:01 AM · Restricted Project
arichardson updated the diff for D100999: [lld-macho] Fix BUILD_SHARED_LIBS build.

address review feedback

Apr 28 2021, 4:30 AM · Restricted Project, Restricted Project
arichardson committed rG79030a22cc0f: [llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL (authored by arichardson).
[llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL
Apr 28 2021, 4:24 AM
arichardson committed rGaed66d278768: [ELF] Update URL for MIPS TLS wiki page (authored by arichardson).
[ELF] Update URL for MIPS TLS wiki page
Apr 28 2021, 4:24 AM
arichardson committed rG777ca513c864: [builtins] Fix ABI-incompatibility with GCC for floating-point compare (authored by arichardson).
[builtins] Fix ABI-incompatibility with GCC for floating-point compare
Apr 28 2021, 4:24 AM
arichardson committed rG9692811b2646: [update_(llc_)test_checks.py] Support pre-processing commands (authored by arichardson).
[update_(llc_)test_checks.py] Support pre-processing commands
Apr 28 2021, 4:23 AM
arichardson closed D100489: [llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL.
Apr 28 2021, 4:23 AM · Restricted Project
arichardson closed D100949: [ELF] Update URL for MIPS TLS wiki page.
Apr 28 2021, 4:23 AM · Restricted Project
arichardson closed D98205: [builtins] Fix ABI-incompatibility with GCC for floating-point compare.
Apr 28 2021, 4:23 AM · Restricted Project
arichardson closed D95137: [update_(llc_)test_checks.py] Support pre-processing commands.
Apr 28 2021, 4:23 AM · Restricted Project
arichardson added a comment to D48803: Place the BlockAddress type in the address space of the containing function.

I will commit this based on the previous approval in 1 month (1st June) unless there are any further comments.

Looks like this wasn't re-approved after the changes were requested.
I would suggest submitting an RFC to llvm-dev.

Apr 28 2021, 3:13 AM · Restricted Project
arichardson added a comment to D48803: Place the BlockAddress type in the address space of the containing function.

I will commit this based on the previous approval in 1 month (1st June) unless there are any further comments.

Apr 28 2021, 1:50 AM · Restricted Project

Apr 27 2021

arichardson planned changes to D100490: [ELF] Refactor DynamicReloc to fix incorrect relocation addends.

Maybe OutputSection::checkDynRelAddends() should be moved to a separate patch and this one just does the DynamicReloc refactoring that fixes ppc64-abs64-dyn.s and got32-i386-pie-rw.s with -z rela.
@MaskRay would that make reviewing the patch easier?

I am still unclear that we want to do OutputSection::checkDynRelAddends() unconditionally. It is probably a good addition for LLVM_ENABLE_ASSERTIONS=on builds.

The improvement bits should definitely be separate from the check bits.

Apr 27 2021, 2:51 PM · Restricted Project
arichardson abandoned D99943: [llvm-reduce] Skip dso_local reduction step that results in invalid IR.

Superseded by D101279

Apr 27 2021, 3:10 AM · Restricted Project
arichardson accepted D101279: [llvm-reduce] Don't unset dso_local on implicitly dso_local GVs.

Supersedes D99943.
Maybe adding AbortOnInvalidReduction should be a separate commit, but the overall diff looks good to me.

Apr 27 2021, 3:09 AM · Restricted Project

Apr 23 2021

arichardson added a comment to D100490: [ELF] Refactor DynamicReloc to fix incorrect relocation addends.

Maybe OutputSection::checkDynRelAddends() should be moved to a separate patch and this one just does the DynamicReloc refactoring that fixes ppc64-abs64-dyn.s and got32-i386-pie-rw.s with -z rela.
@MaskRay would that make reviewing the patch easier?

Apr 23 2021, 4:04 AM · Restricted Project
arichardson added a comment to D100490: [ELF] Refactor DynamicReloc to fix incorrect relocation addends.

I've had a quick read through and I like where this is going. There's a lot to check through and I've run out of time today. I've left a couple of small suggestions. Will need to come back and look in more detail, probably next week to see if I've got anything else to add.

Apr 23 2021, 4:01 AM · Restricted Project

Apr 22 2021

arichardson added a comment to D100762: [clang][cli] Extract AST dump format into extra option.

If -ast-dump=json was a driver flag, it would be trivial to pass -ast-dump -ast-dump-format json to -cc1 instead. However, aliasing a single option to two options within the -cc1 argument parser isn't possible at the moment AFAIK. I can look into how much work adding that capability would be.

@arichardson Can you point me to the external consumers?

Apr 22 2021, 2:30 AM · Restricted Project, Restricted Project, Restricted Project

Apr 21 2021

arichardson requested review of D100999: [lld-macho] Fix BUILD_SHARED_LIBS build.
Apr 21 2021, 2:59 PM · Restricted Project, Restricted Project
arichardson requested review of D100949: [ELF] Update URL for MIPS TLS wiki page.
Apr 21 2021, 6:18 AM · Restricted Project
arichardson updated the diff for D100490: [ELF] Refactor DynamicReloc to fix incorrect relocation addends.

Drop unrelated changes

Apr 21 2021, 6:17 AM · Restricted Project
arichardson added inline comments to D100490: [ELF] Refactor DynamicReloc to fix incorrect relocation addends.
Apr 21 2021, 6:13 AM · Restricted Project
arichardson added a comment to D98261: [builtins] Support building the 128-bit float functions on x86.

If I am not misreading this, this patch changes the implementation of at least __powitf2 to no longer use long double but __float128. Such changes will not work on PowerPC because there are two different 128-bit floating point types on PPC - the "PPC double double" and IEEE-754 quad precision. And long double could mean either one of those (depending on -mabi=ieeelongdouble). The tf libcalls on PPC are used for long double whereas kf ones are used for explicit __float128.

Apr 21 2021, 5:47 AM · Restricted Project
arichardson added inline comments to D100835: [WIP][LLD][RISCV] Linker Relaxation.
Apr 21 2021, 4:46 AM · Restricted Project
arichardson updated the diff for D98261: [builtins] Support building the 128-bit float functions on x86.
  • fix tests on platforms without 128-floating point types (e.g. x86 macOS)
Apr 21 2021, 4:17 AM · Restricted Project
arichardson added a comment to D48803: Place the BlockAddress type in the address space of the containing function.

@arsenm / @dylanmckay is this okay to commit now?

Apr 21 2021, 4:03 AM · Restricted Project
arichardson updated the diff for D100544: [ELF][AArch64] Write addends for TLSDESC relocations with -z rel.
  • fix doc comment
Apr 21 2021, 3:51 AM · Restricted Project
arichardson updated the diff for D100544: [ELF][AArch64] Write addends for TLSDESC relocations with -z rel.

Rebase on top of D100489

Apr 21 2021, 3:49 AM · Restricted Project
arichardson added inline comments to D100490: [ELF] Refactor DynamicReloc to fix incorrect relocation addends.
Apr 21 2021, 3:27 AM · Restricted Project
arichardson added inline comments to D100490: [ELF] Refactor DynamicReloc to fix incorrect relocation addends.
Apr 21 2021, 3:25 AM · Restricted Project
arichardson updated the diff for D100490: [ELF] Refactor DynamicReloc to fix incorrect relocation addends.

Use an enum instead of the highly overloaded useSymVA. Hopefully the logic is easier to follow now.

Apr 21 2021, 3:25 AM · Restricted Project

Apr 19 2021

arichardson requested changes to D100762: [clang][cli] Extract AST dump format into extra option.

I'm not sure it's a good idea to remove the -ast-dump=json option. While this is -cc1 option, there do seem to be external consumers based on a quick search for "-ast-dump=json". Keeping it would also reduce some of the test churn.

Apr 19 2021, 11:43 AM · Restricted Project, Restricted Project, Restricted Project
arichardson added inline comments to D100489: [llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL.
Apr 19 2021, 11:28 AM · Restricted Project
arichardson updated the diff for D100489: [llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL.

Address review feedback from @jhenderson

Apr 19 2021, 11:27 AM · Restricted Project
arichardson added inline comments to D100717: [InstCombine] Transform memcpy to ptr load/stores if TBAA says so.
Apr 19 2021, 10:30 AM · Restricted Project
arichardson updated subscribers of D100717: [InstCombine] Transform memcpy to ptr load/stores if TBAA says so.

First thought: Why is there no test in which we generate no int2ptr with the patch but do without?

@fhahn: I don't see how this use of TBAA metadata is within the specification of the metadata.

I read through the code and I'm not sure if this is even a semantic change. I mean, can't we pick any
type to do the memory transfer expansion? If so, TBAA metadata as a heuristic should be totally fine.
We could also look at uses of the source and target pointers, for example. That said, we should write
in the lang ref that we do use the TBAA names for heuristics and they should be chosen to match the code/intent.

Apr 19 2021, 10:18 AM · Restricted Project
arichardson added inline comments to D100489: [llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL.
Apr 19 2021, 6:27 AM · Restricted Project
arichardson retitled D100489: [llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL from [llvm-readobj] Fix dumping dynamic relative relocations for SHT_REL to [llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL.
Apr 19 2021, 6:21 AM · Restricted Project
arichardson added a comment to D100490: [ELF] Refactor DynamicReloc to fix incorrect relocation addends.

The getImplicitAddend enhancement (-z rel) can be moved to a separate patch, but the dynamic only relocation types (JUMP_SLOT, RELATIVE, IRELATIVE, etc) should be removed since they can't be input.

useSymVA is subtle and I need time to grok it. I wonder whether the new member can improve https://bugs.llvm.org/show_bug.cgi?id=47009 TLSDESC for -z rel?

Apr 19 2021, 4:33 AM · Restricted Project
arichardson added inline comments to D100489: [llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL.
Apr 19 2021, 2:25 AM · Restricted Project

Apr 15 2021

arichardson committed rGf511dc75e4c1: [asan] Add an offset for the kernel address sanitizer on FreeBSD (authored by Mark Johnston <markjdb@gmail.com>).
[asan] Add an offset for the kernel address sanitizer on FreeBSD
Apr 15 2021, 9:49 AM
arichardson committed rG99eca1bd9c7a: [Driver] Enable kernel address and memory sanitizers on FreeBSD (authored by markj).
[Driver] Enable kernel address and memory sanitizers on FreeBSD
Apr 15 2021, 9:49 AM
arichardson closed D98285: [asan] Add an offset for the kernel address sanitizer on FreeBSD.
Apr 15 2021, 9:49 AM · Restricted Project
arichardson closed D98286: [Driver] Enable kernel address and memory sanitizers on FreeBSD.
Apr 15 2021, 9:49 AM · Restricted Project
arichardson added a comment to D98285: [asan] Add an offset for the kernel address sanitizer on FreeBSD.

Is there anything I can do to get this committed? I'd like to import KASAN support to FreeBSD but of course this change and D298286 are prerequisites.

Apr 15 2021, 8:33 AM · Restricted Project
arichardson updated the diff for D100544: [ELF][AArch64] Write addends for TLSDESC relocations with -z rel.

Fix the failing amd64 test

Apr 15 2021, 5:58 AM · Restricted Project
arichardson added a comment to D100544: [ELF][AArch64] Write addends for TLSDESC relocations with -z rel.

Breaks lld/test/ELF/x86-64-tlsdesc-gd.s, will investigate.

Apr 15 2021, 5:41 AM · Restricted Project
arichardson added a comment to D100490: [ELF] Refactor DynamicReloc to fix incorrect relocation addends.

The getImplicitAddend enhancement (-z rel) can be moved to a separate patch, but the dynamic only relocation types (JUMP_SLOT, RELATIVE, IRELATIVE, etc) should be removed since they can't be input.

useSymVA is subtle and I need time to grok it. I wonder whether the new member can improve https://bugs.llvm.org/show_bug.cgi?id=47009 TLSDESC for -z rel?

Apr 15 2021, 4:17 AM · Restricted Project
arichardson requested review of D100544: [ELF][AArch64] Write addends for TLSDESC relocations with -z rel.
Apr 15 2021, 4:16 AM · Restricted Project
arichardson added inline comments to D100490: [ELF] Refactor DynamicReloc to fix incorrect relocation addends.
Apr 15 2021, 3:34 AM · Restricted Project
arichardson added a comment to D100490: [ELF] Refactor DynamicReloc to fix incorrect relocation addends.

The getImplicitAddend enhancement (-z rel) can be moved to a separate patch, but the dynamic only relocation types (JUMP_SLOT, RELATIVE, IRELATIVE, etc) should be removed since they can't be input.

useSymVA is subtle and I need time to grok it. I wonder whether the new member can improve https://bugs.llvm.org/show_bug.cgi?id=47009 TLSDESC for -z rel?

Apr 15 2021, 3:00 AM · Restricted Project
arichardson updated the diff for D100489: [llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL.
  • remove debug RUN: line
Apr 15 2021, 2:39 AM · Restricted Project
arichardson added a comment to D100489: [llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL.

Hopefully the new test is better?

Apr 15 2021, 2:38 AM · Restricted Project
arichardson updated the diff for D100489: [llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL.

Improve test

Apr 15 2021, 2:38 AM · Restricted Project
arichardson updated the diff for D100489: [llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL.
  • simplify test case
Apr 15 2021, 2:26 AM · Restricted Project

Apr 14 2021

arichardson planned changes to D100489: [llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL.
Apr 14 2021, 12:29 PM · Restricted Project
arichardson retitled D100489: [llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL from [UPSTREAM][llvm-readobj] Fix dumping dynamic relative relocations for SHT_REL to [llvm-readobj] Fix dumping dynamic relative relocations for SHT_REL.
Apr 14 2021, 9:10 AM · Restricted Project
arichardson published D100489: [llvm-objdump] Fix dumping dynamic relative relocations for SHT_REL for review.
Apr 14 2021, 9:09 AM · Restricted Project
arichardson requested review of D100490: [ELF] Refactor DynamicReloc to fix incorrect relocation addends.
Apr 14 2021, 9:08 AM · Restricted Project

Apr 9 2021

arichardson committed rGdc4abca7662b: Handle alloc_size attribute on function pointers (authored by arichardson).
Handle alloc_size attribute on function pointers
Apr 9 2021, 10:50 AM
arichardson committed rGed0bf875a93e: [builtins] Avoid enum name conflicts with fenv.h (authored by arichardson).
[builtins] Avoid enum name conflicts with fenv.h
Apr 9 2021, 10:50 AM
arichardson committed rG107189a26eef: [TableGen] Report an error message on a missing comma (authored by arichardson).
[TableGen] Report an error message on a missing comma
Apr 9 2021, 10:50 AM
arichardson closed D55212: Handle alloc_size attribute on function pointers.
Apr 9 2021, 10:50 AM · Restricted Project
arichardson closed D98333: [builtins] Avoid enum name conflicts with fenv.h.
Apr 9 2021, 10:50 AM · Restricted Project
arichardson closed D100178: [TableGen] Report an error message on a missing comma.
Apr 9 2021, 10:50 AM · Restricted Project
arichardson updated the diff for D95137: [update_(llc_)test_checks.py] Support pre-processing commands.
  • fix pre-processing test after output changes
Apr 9 2021, 9:51 AM · Restricted Project
arichardson updated the diff for D100054: Handle flags such as -m32 when computing the prefix for programs/runtime libs.
  • Fix Windows path regex
Apr 9 2021, 8:51 AM · Restricted Project
arichardson added a comment to D98205: [builtins] Fix ABI-incompatibility with GCC for floating-point compare.

If there are no further comments, I will commit this early next week.

Apr 9 2021, 8:44 AM · Restricted Project
arichardson updated the diff for D100178: [TableGen] Report an error message on a missing comma.

Add a test

Apr 9 2021, 4:48 AM · Restricted Project
arichardson requested review of D100178: [TableGen] Report an error message on a missing comma.
Apr 9 2021, 4:27 AM · Restricted Project
arichardson added a comment to D97462: [clang][cli] Round-trip cc1 arguments in assert builds.

I just merged this commit into our CHERI fork and noticed some failing tests due to round tripping:
We add some additional CodeGenOptions and LangOptions, but are not including those in the generated command line.

For example, I added an additional std::string CHERIStatsFile; to CodeGenOptions. This is set inside bool CompilerInvocation::ParseCodeGenArgs using Opts.CHERIStatsFile = Args.getLastArgValue(OPT_cheri_stats_file).str();.
I haven't added logic to round trip this flag (yet). If CC1 argument round tripping is enabled, the flag is stripped and the output goes to stderr instead of the defined file, causing some tests to fail.

Unfortunately this is not caught by any assertions, so I worry that there are other arguments that might be silently removed after this commit. Are there any open reviews/plans to check CodeGenOptions/etc, for equality after round-tripping?

We currently don't have the infrastructure to compare CompilerInvocation instances directly. Instead we rely on good test coverage of command line options: if the round-tripped CompilerInvocation doesn't contain the option, tests will fail. You can then check the generated command lines by passing -Rround-trip-cc1-args to the failing CC1 invocation.

There was an attempt to generate operator== for CompilerInvocation and assert when the round-tripped instance isn't equal to the original, as you suggest. This is the patch that started by moving members to definition databases, but it got reverted: D86290.

Apr 9 2021, 2:18 AM · Restricted Project

Apr 8 2021

arichardson added a comment to D97462: [clang][cli] Round-trip cc1 arguments in assert builds.

I just merged this commit into our CHERI fork and noticed some failing tests due to round tripping:
We add some additional CodeGenOptions and LangOptions, but are not including those in the generated command line.

Apr 8 2021, 9:26 AM · Restricted Project
arichardson updated the diff for D100054: Handle flags such as -m32 when computing the prefix for programs/runtime libs.

Drop chunk that is no longer necessary

Apr 8 2021, 4:45 AM · Restricted Project
arichardson updated the diff for D100054: Handle flags such as -m32 when computing the prefix for programs/runtime libs.

Add the raw triple prefix for programs (but prefer the adjusted triple) and always use the adjusted triple for libraries.
Should hopefully address the feedback from @joerg.

Apr 8 2021, 4:43 AM · Restricted Project
arichardson retitled D100054: Handle flags such as -m32 when computing the prefix for programs/runtime libs from Handle flags such as -m32 when computing the triple prefix for programs to Handle flags such as -m32 when computing the prefix for programs/runtime libs.
Apr 8 2021, 4:40 AM · Restricted Project
arichardson abandoned D95370: [ELF] Infer OSABI from input files for -m options without explicit OSABI.

No longer necessary

Apr 8 2021, 1:31 AM · Restricted Project

Apr 7 2021

arichardson planned changes to D100054: Handle flags such as -m32 when computing the prefix for programs/runtime libs.

This sounds wrong. If you are using 'x86_64-freebsd' as triple and -m32, it should still call 'x86_64-freebsd-ld', but it is the responsibility of the driver to ensure that also the right set of linker flags are passed as well. Compare netbsd::Linker::ConstructJob for one way to handle this.

Apr 7 2021, 2:38 PM · Restricted Project