1. Apr 06, 2021
  2. Apr 05, 2021
    • Erik Pilkington's avatar
      [SemaObjC] Fix a -Wbridge-cast false-positive · 803b7922
      Erik Pilkington authored
      Clang used to emit a bad -Wbridge-cast diagnostic on the cast in the attached
      test. This was because, after 09abecef, struct __CFString was not added to
      lookup, so the objc_bridge attribute wasn't getting duplicated onto the most
      recent declaration, causing us to fail to find it in getObjCBridgeAttr. This
      patch fixes this by instead walking through the redeclarations to find an
      appropriate bridge attribute. rdar://72823399
      
      Differential revision: https://reviews.llvm.org/D99661
      803b7922
    • Stefan Pintilie's avatar
      [PowerPC] Fix issue where binary uses a .got but is missing a .TOC. · 660c4e57
      Stefan Pintilie authored
      From the PowerPC ELFv2 ABI section 4.2.3. Global Offset Table.
      ```
      The GOT consists of an 8-byte header that contains the TOC base (the first TOC
      base when multiple TOCs are present), followed by an array of 8-byte addresses.
      ```
      
      Due to the introduction of PC Relative code it is now possible to require a GOT
      without having a .TOC. symbol in the object that is being linked. Since LLD uses
      the .TOC. symbol to determine whether or not a GOT is required the GOT header is
      not setup correctly and the 8-byte header is missing.
      
      This patch allows the Power PC GOT setup to happen when an element is added to
      the GOT instead of at the very begining. When this header is added a .TOC.
      symbol is also added.
      
      Reviewed By: MaskRay
      
      Differential Revision: https://reviews.llvm.org/D91426
      660c4e57