Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DO NOT MERGE] Apply Rust patches on release/8.x #1

Closed
wants to merge 25 commits into from

Commits on Jan 16, 2019

  1. Add accessors for MCSubtargetInfo CPU and Feature tables

    This is needed for `-C target-cpu=help` and `-C target-feature=help` in rustc
    bitshifter authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    865c1f7 View commit details
    Browse the repository at this point in the history
  2. Fix compile on dist-i686-linux builder

    If this lines are present then we apparently get errors [1] when compiling in
    the current [2] dist-i686-linux container. Attempts to upgrade both gcc and
    binutils did not fix the error, so it appears that this may just be a bug in the
    super old glibc we're using on the dist-i686-linux container.
    
    We don't actually need this code anyway, so just work around these issues by
    removing references to the `*64` functions. This'll get things compiling
    locally and shouldn't be a regression in functionality.
    
    [1]: https://travis-ci.org/rust-lang/rust/jobs/257578199
    [2]: https://github.com/rust-lang/rust/tree/eba9d7f08ce5c90549ee52337aca0010ad566f0d/src/ci/docker/dist-i686-linux
    alexcrichton authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    122c3dc View commit details
    Browse the repository at this point in the history
  3. Disable checks for libatomic for now

    For whatever reason this is failing the i686-freebsd builder in the Rust repo
    as-of this red-hot moment. The build seems to work fine without it so let's just
    remove it for now and pray there's a better fix later.
    
    Although if you're reading this and know of a better fix, we'd love to remove
    this!
    alexcrichton authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    b73884a View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    392947a View commit details
    Browse the repository at this point in the history
  5. Fix compile on dist-x86_64-linux builder

    Apparently glibc is so old it doesn't have the _POSIX_ARG_MAX constant. This
    shouldn't affect anything we use anyway though.
    
    https://travis-ci.org/rust-lang/rust/jobs/399333071
    alexcrichton authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    bd18bd8 View commit details
    Browse the repository at this point in the history
  6. Compile with /MT on MSVC

    Can't seem to figure out how to do this without this patch...
    alexcrichton authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    b1ec4cb View commit details
    Browse the repository at this point in the history
  7. Add Rust support to Mangled

    This adds Rust support to Mangled.  I am not completely certain that
    this is needed (or alternatively that it does enough, maybe
    Mangled::GuessLanguage needs a Rust case).  This should be checked
    before attempting to upstream.
    tromey authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    1ecf8ed View commit details
    Browse the repository at this point in the history
  8. Add DIERef::operator==

    This was needed for the Rust plugin
    tromey authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    9fa3339 View commit details
    Browse the repository at this point in the history
  9. Add a missing TypeAndOrName constructor

    Add a TypeAndOrName constructor that was declared but not defined.
    This is used in the Rust plugin.  See https://reviews.llvm.org/D44752
    tromey authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    e6a7452 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    ea4ac97 View commit details
    Browse the repository at this point in the history
  11. The Rust plugin

    tromey authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    df47965 View commit details
    Browse the repository at this point in the history
  12. Compute Python library suffix in CMakeLists.txt

    Introduce LLDB_PY_LIB_SUFFIX and use it in various places in the
    build.  This lets the x.py-based build work properly without having to
    set LLVM_LIBDIR_SUFFIX.
    
    See https://bugs.llvm.org/show_bug.cgi?id=18957 for some discussion.
    tromey authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    b8bd5dc View commit details
    Browse the repository at this point in the history
  13. Do not crash when enum discriminant is not recognized

    Sometimes the DWARF can omit information about a discriminant, for
    example when an Option shares a discriminant slot with an enum that it
    wraps.  In this case, lldb could crash, because the discriminant was
    not found and because there was no default variant.
    
    No test case because this relies on a compiler bug that will soon be
    fixed.
    
    Fixes llvm#16
    tromey authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    02ddf76 View commit details
    Browse the repository at this point in the history
  14. Use correct include path for State.h

    While rebasing to master, I missed a spot where an include file was
    moved.  I believe my local build was picking up an installed copy of
    the header, causing it to succeed locally.
    tromey authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    0e77fbd View commit details
    Browse the repository at this point in the history
  15. Add "rust-enabled" to --version output

    This adds "rust-enabled" to the --version output, so it's easier to
    tell if lldb has rust support.
    tromey authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    0322285 View commit details
    Browse the repository at this point in the history
  16. Fix handling of variant parts

    This fixes a couple of problems noticed while debugging the rust
    compiler change to use DW_TAG_variant_part:
    
    * IterableDIEChildren returned one extra DIE, because it did not
      preserve the CU in end()
    
    * The entire block dealing with DW_TAG_variant_part was erroneously
      inside the DW_TAG_member case.
    tromey authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    d957e27 View commit details
    Browse the repository at this point in the history
  17. Give names to tuple fields

    This gives numeric names to tuple fields, because lldb clients expect
    fields to have names, and because using plain numbers seemed most
    rust-like.
    
    Closes llvm#21
    tromey authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    463cd70 View commit details
    Browse the repository at this point in the history
  18. Rename tuple fields after discriminant is removed

    When the discriminant is removed from an enum's members, be sure to
    rename the fields of any tuple type.  This fixes a bug introduced in
    yesterday's patch.
    tromey authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    945de34 View commit details
    Browse the repository at this point in the history
  19. Fix field names when emitting a C structure

    Prepend an underscore to field names when emitting a C structure, to
    ensure that tuple fields have valid names.
    tromey authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    ff0a15a View commit details
    Browse the repository at this point in the history
  20. Remove by-name cache from RustASTContext

    Remove the by-name cache from RustASTContext.  This was not needed and
    could interact badly with the DWARF parser.  Closes llvm#22
    tromey authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    28e0138 View commit details
    Browse the repository at this point in the history
  21. Disable enum type test

    This disables aaan enum type name test that is failing with git master
    rustc.  See llvm#24.
    tromey authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    af32307 View commit details
    Browse the repository at this point in the history
  22. Read template parameters for structure types

    Read DW_TAG_template_type_parameter and apply to structure types.
    tromey authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    2ed5e5d View commit details
    Browse the repository at this point in the history
  23. Read template parameters for function types

    Read DW_TAG_template_type_parameter and apply to function types.
    
    Closes llvm#5
    tromey authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    8027847 View commit details
    Browse the repository at this point in the history
  24. Fix the build after the rebase

    The rebase onto a later git master lldb required a change to
    RustASTContext.
    tromey authored and cuviper committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    0fb81ce View commit details
    Browse the repository at this point in the history
  25. Configuration menu
    Copy the full SHA
    a27fbee View commit details
    Browse the repository at this point in the history