- User Since
- Sep 4 2015, 4:18 PM (142 w, 1 d)
Wed, May 23
LGTM. Also looks like it should be easy to adjust our CHERI ll/sc instructions to use the same mechanism when I do the next upstream merge.
As I have mentioned before, having this patch is the difference between LLD being completely unusable for our purposes (linking FreeBSD MIPS n64) and being able to replace BFD.
Wed, May 16
Tue, May 15
Address review comment
Mon, May 7
I recently made this change for the CHERI clang fork and as far as I can tell everything works fine.
Apr 20 2018
Perform the optimization in LegalizeDAG instead. Turns out this also fixes MSP430
This approach is wrong and I currently don't have time to work on a correct solution.
Apr 18 2018
Apr 13 2018
Thank you very much for updating this patch! I will be merging from upstream LLVM soon and having this rebased makes the merging so much easier.
Apr 12 2018
LGTM other than adding a gap between MIPS tags and PPC tags
Apr 11 2018
Apr 10 2018
So, for the moment, we are only handling basic types. That said, for the enum in C, we will print according to the type of the enum.
In the future versions, I really want to be able to print the name of the enum so that the output is more relevent.
Anyway, the rule I followed for the moment is : if I don't recognize the type, I print it as an address.
Seems like at -O2 clang 5.0.0 can optimize away all the optional checks (https://godbolt.org/g/rbGYrN)
This is wrong
I'm also often restricted to using printf for debugging so this looks really useful!
Apr 6 2018
Apr 2 2018
Mar 27 2018
Mar 26 2018
Mar 21 2018
Mar 20 2018
Address review comments
Mar 17 2018
Mar 16 2018
Use correct version of diff
Mar 14 2018
I've fixed the typo in my commit message. I think either name is fine (or even update_clang_test_checks.py).
I just ran into this problem writing a test case and for now I used the workaround by @probinson but having a CHECK-EMPTY directive would make it much cleaner.
Just tested it and it works perfectly for me.
Mar 13 2018
The reason that this is a MIPS test case is that I work on CHERI (which extends MIPS) and therefore most of the testcases I write are derived from MIPS input.
Mar 2 2018
No need to revert, I think it is fine to improve the script in follow-up revisions. Thanks again for working on this!
LGTM, I guess the CHECK-LABEL thing can be fixed later.
LGTM but I guess someone else should approve
Turns out we can't emit R_MIPS_64 absolute relocations that don't need the GOT since neither glibc nor FreeBSD handle a R_MIPS_64 dynamic relocations.
If I have the following:
// RUN: %clang_cc1 -emit-llvm -o - %s -O2 | FileCheck %s
Mar 1 2018
The FreeBSD rtld supports both so this LGTM. Emitting both is probably more compatible but I'm not sure it's required. What does ld.bfd do?
Added the correct version of the test
Feb 28 2018
Thanks for working on this!
Feb 27 2018
Feb 26 2018
Thanks for working on this, it will make life a lot easier for us when it lands.
Feb 23 2018
I can verify that without this patch pie executables crash inside the FreeBSD (CheriBSD) RTLD when processing DT_MIPS_RLD_MAP and with it they work.
Feb 22 2018
Feb 20 2018
It seems like changing all alloc sections to NOBITS is probably the correct way of doing this. So I guess D40523 adjusted to always keep the named debug sections is better.
I don't think any of them are SHF_ALLOC anyway but checking the names shouldn't do any harm.
Looks good once the IR parser accepts calls to non-AS0 pointers.
Feb 19 2018
Feb 16 2018
Addressed review comment
Thank you very much for updating this patch! I have just made the switch in CheriBSD to completely stop using ld.bfd and so far everything I have tested is working.
Feb 15 2018
- Updated comments to Rafael's suggestions
Feb 14 2018
Shrink patch even more to address only the issue in the test case
Feb 12 2018
Since this is not the correct solution I'll just keep this in our fork.
The way it is currently it is emitting dynamic relocations into the .text segment. This needs -Wl,-z,notext with LLD but for BFD it will just emit those relocations anyway and (probably) crash at runtime.
At least now we are explicit that it requires a writable section (which will be in the relro section if you are using LLD).
Feb 10 2018
- Split out an unrelated change to D43161
- made the diff smaller
Feb 9 2018
Okay I won't bother submitting further improvements that actually allow us to run the test suite without crashing.