1. 15 8月, 2023 1 次提交
  2. 14 7月, 2023 1 次提交
  3. 08 7月, 2023 1 次提交
  4. 27 6月, 2023 1 次提交
  5. 21 4月, 2023 1 次提交
  6. 03 4月, 2023 1 次提交
  7. 02 9月, 2022 2 次提交
    • N
      Use boxed slices in `PatKind`. · 43a0268f
      Nicholas Nethercote 提交于
      To shrink it a little more.
      43a0268f
    • N
      Clean up THIR patterns. · 053874ee
      Nicholas Nethercote 提交于
      `thir::Pat::kind` is a `Box<PatKind>`, which doesn't follow the usual
      pattern in AST/HIR/THIR which is that the "kind" enum for a node is
      stored inline within the parent struct.
      
      This commit makes the `PatKind` directly inline within the `Pat`. This
      requires using `Box<Pat>` in all the types that hold a `Pat.
      
      Ideally, `Pat` would be stored in `Thir` like `Expr` and `Stmt` and
      referred to with a `PatId` rather than `Box<Pat>`. But this is hard to
      do because lots of `Pat`s get created after the destruction of the `Cx`
      that does normal THIR building. But this does get us a step closer to
      `PatId`, because all the `Box<Pat>` occurrences would be replaced with
      `PatId` if `PatId` ever happened.
      
      At 128 bytes, `Pat` is large. Subsequent commits will shrink it.
      053874ee
  8. 24 8月, 2022 4 次提交
  9. 12 7月, 2022 1 次提交
  10. 09 7月, 2022 1 次提交
    • R
      don't allow ZST in ScalarInt · a422b421
      Ralf Jung 提交于
      There are several indications that we should not ZST as a ScalarInt:
      - We had two ways to have ZST valtrees, either an empty `Branch` or a `Leaf` with a ZST in it.
        `ValTree::zst()` used the former, but the latter could possibly arise as well.
      - Likewise, the interpreter had `Immediate::Uninit` and `Immediate::Scalar(Scalar::ZST)`.
      - LLVM codegen already had to special-case ZST ScalarInt.
      
      So instead add new ZST variants to those types that did not have other variants
      which could be used for this purpose.
      a422b421
  11. 24 5月, 2022 1 次提交
    • T
      Fix precise field capture of univariant enums · 0e7eca77
      Tomasz Miąsko 提交于
      When constructing a MIR from a THIR field expression, introduce an
      additional downcast projection before accessing a field of an enum.
      
      When rebasing a place builder on top of a captured place, account for
      the fact that a single HIR enum field projection corresponds to two MIR
      projection elements: a downcast element and a field element.
      0e7eca77
  12. 14 4月, 2022 1 次提交
  13. 06 4月, 2022 1 次提交
  14. 02 4月, 2022 3 次提交
  15. 23 3月, 2022 4 次提交
  16. 08 3月, 2022 2 次提交
  17. 21 2月, 2022 1 次提交
    • M
      Revert "Auto merge of #93800 - b-naber:static-initializers-mir-val, r=oli-obk" · 9f762148
      Mark Rousskov 提交于
      This reverts commit a240ccd8, reversing
      changes made to 393fdc10.
      
      This PR was likely responsible for a relatively large regression in
      dist-x86_64-msvc-alt builder times, from approximately 1.7 to 2.8 hours,
      bringing that builder into the pool of the slowest builders we currently have.
      
      This seems to be limited to the alt builder due to needing parallel-compiler
      enabled, likely leading to slow LLVM compilation for some reason.
      9f762148
  18. 16 2月, 2022 1 次提交
  19. 15 2月, 2022 1 次提交
    • N
      Overhaul `Const`. · a95fb8b1
      Nicholas Nethercote 提交于
      Specifically, rename the `Const` struct as `ConstS` and re-introduce `Const` as
      this:
      ```
      pub struct Const<'tcx>(&'tcx Interned<ConstS>);
      ```
      This now matches `Ty` and `Predicate` more closely, including using
      pointer-based `eq` and `hash`.
      
      Notable changes:
      - `mk_const` now takes a `ConstS`.
      - `Const` was copy, despite being 48 bytes. Now `ConstS` is not, so need a
        we need separate arena for it, because we can't use the `Dropless` one any
        more.
      - Many `&'tcx Const<'tcx>`/`&Const<'tcx>` to `Const<'tcx>` changes
      - Many `ct.ty` to `ct.ty()` and `ct.val` to `ct.val()` changes.
      - Lots of tedious sigil fiddling.
      a95fb8b1
  20. 13 1月, 2022 1 次提交
  21. 09 9月, 2021 2 次提交