1. Jun 06, 2020
  2. Jun 05, 2020
    • Simon Pilgrim's avatar
      [X86][SSE] Simplify MOVMSK patterns based on comparison · d194ff31
      Simon Pilgrim authored
      An initial patch adding combineSetCCMOVMSK to simplify MOVMSK and its vector input based on the comparison of the MOVMSK result.
      
      This first stage just adds support for some simple MOVMSK(PACKSSBW()) cases where we remove the PACKSS if we're comparing ne/eq zero (any_of patterns), allowing us to directly compare against the v8i16 source vector(s) bitcasted to v16i8, with suitable masking to take into account of which signbits are valid.
      
      Future combines could peek through further PACKSS, target shuffles, handle all_of patterns (ne/eq -1), optimize to a PTEST op, etc.
      
      Differential Revision: https://reviews.llvm.org/D81171
      d194ff31
    • Xun Li's avatar
      Fix the roundtrip test under llvm-profdata · 45f58bf4
      Xun Li authored
      Summary:
      According to the comments, we want to convert the profile into two binary formats, and then into the md5text format.
      We seems to have ignored the intermediate files.
      This patch uses them to complete the full roundtrips.
      
      Reviewers: wmi, wenlei
      
      Reviewed By: wmi
      
      Subscribers: llvm-commits
      
      Tags: #llvm
      
      Differential Revision: https://reviews.llvm.org/D81202
      45f58bf4
    • Pete Steinfeld's avatar
      [flang] Fix crash on erroneous expressions · 4d8c00c0
      Pete Steinfeld authored
      Summary:
      If you create an expression with parse errors, the `parser::Expr.typedExpr`
      will be empty, which causes a compiler crash.  The crash is caused by the
      check in check-do-forall.cpp that scans all expresssions to see if `DO`
      variables are being modified.
      
      It turned out that the problem was that I was fetching subexpressions of type
      `parser::Expr`, which are not guaranteed to have a non-null `typedExpr`.  I
      fixed this by only grabbing the top-level expression from which to gather
      arguments as part of the DO loop analysis.  This, in turn, exposed a problem
      where I wasn't collecting all of the actual arguments in an expression.  This
      was caused by the fact that I wasn't recursing through the rest of the
      expression after finding an argument.  I fixed this by recursing through the
      argument in the member function in `CollectActualArgumentsHelper`.
      
      Reviewers: klausler, tskeith, DavidTruby
      
      Subscribers: llvm-commits
      
      Tags: #llvm
      
      Differential Revision: https://reviews.llvm.org/D81101
      4d8c00c0
    • Fangrui Song's avatar
      [ELF] Handle -u before input files · 7bee6e30
      Fangrui Song authored
      If both a.a and b.so define foo
      
      ```
      ld.bfd -u foo a.a b.so  # foo is defined
      ld.bfd a.a b.so -u foo  # foo is defined
      ld.bfd -u foo b.so a.a  # foo is undefined (provided at runtime by b.so)
      ld.bfd b.so a.a -u foo  # foo is undefined (provided at runtime by b.so)
      ```
      
      In all cases we make foo undefined in the output.  I tend to think the
      GNU ld behavior makes more sense.
      
      * In their model, they have to treat -u as a fake object file with an
        undefined symbol before all input files, otherwise the first archive would not be fetched.
      * Following their behavior allows us to drop a --warn-backrefs special case.
      
      Reviewed By: psmith
      
      Differential Revision: https://reviews.llvm.org/D81052
      7bee6e30
    • Zinovy Nis's avatar
      Fix crash on misc-redundant-expression · c063b4a7
      Zinovy Nis authored
      Differential Revision: https://reviews.llvm.org/D80896
      c063b4a7
    • Jonas Devlieghere's avatar
      [dsymutil] Don't emit N_AST symbol entries in the Mach-O companion file · fe82d3a3
      Jonas Devlieghere authored
      Treat N_AST symbol table entries like other debug entries and don't emit
      them in the linked binary.
      
      Differential revision: https://reviews.llvm.org/D81205
      fe82d3a3