1. 30 1月, 2021 20 次提交
    • O
      Fix copy-paste error in host_context_test.cpp (#47430) · 13f626fb
      Omair Majid 提交于
      The code tries to write the status from `rcClose`, but accidentally writes
      out the value of `rc` instead.
      13f626fb
    • O
      Use memmove instead of memcpy for overlapping copy (#47468) · d42ac98e
      Omair Majid 提交于
      memcpy is defined to only work when the source and destination memory
      regions do not overlap. In here, they do. So let's use memmove instead.
      d42ac98e
    • O
      Use NewArrayHolder for array type in genanalysis.cpp (#47354) · 7eb29b4b
      Omair Majid 提交于
      Using NewHolder results in the data being `delete` d after it's used.
      The underlying data is an array, so it should be `delete[]` ed instead.
      7eb29b4b
    • O
      Set some pointers to null after free()ing them (#47415) · 5846c212
      Omair Majid 提交于
      These free() calls are done in the middle of the method body; it's
      possible that a duplicate free() can be called on these at the cleanup
      code that runs before the method returns. So set these pointers to null
      after free()ing them to avoid free() already free()d memory.
      5846c212
    • A
      [wasm] Add support for building out-of-tree projects, which use a local runtime build (#47555) · 6299c9c5
      Ankit Jain 提交于
      * [wasm] Add $( WasmBuildAppAfterThisTarget) to control which target
      
      .. triggers WasmAppBuild. Defaults to `Publish`.
      
      * [wasm] emcc, mono-aot-cross doesn't like relative output paths
      
      eg. `-o foo/bar.js`
      
      .. so convert that to absolute paths.
      
      * [wasm] Check for WasmMainJSPath close to it's use
      
      * [wasm] Add new $(WasmGenerateAppBundle) to allow skipping app bundle
      
      .. generation. This is useful when you want to do all the other steps
      for wasm, but handle the packaging/bundle generation yourself. Eg.
      Blazor
      
      * [wasm] Ensure that generated dotnet.{js,wasm} get copied to the app dir
      
      This is usually done as part of the bundle generation (NativeAssets).
      But in cases when that step is being skipped, we still want to copy over
      generated dotnet.{js,wasm} (eg. in case of AOT) to the app dir. This is
      the case that blazor uses.
      
      * [wasm] Allow skipping mono-cil-strip step
      
      In some cases, eg. blazor (till we fix it), `mono-cil-strip` can break
      the app, because of bugs, or linker issues etc.
      
      Also, do this only in the AOT case.
      
      * [wasm] Add support for building wasm projects outside the tree
      
      .. using local runtime builds.
      
      * [wasm] fix up the support for local build dir
      
      * [wasm] add comments for new properties
      
      * [wasm] LocalBuild.*: add more comments, validation
      
      * [wasm] sample: Use BeforeTargets for Prepare target, as a psuedo test for that
      6299c9c5
    • J
      For Reverse P/Invokes, call TraceCall with the entrypoint to the target method. (#47610) · 61a491bd
      Jeremy Koritzinsky 提交于
      Since we're in an IL stub, we don't need to support breakpoints in the stub itself. The debugger will try to resolve the target method and move the breakpoint there. In actuality, that's the part that's failing. Somewhere in the ReversePInvoke helper call chain, we're touching the secret arg register. As a result, when the debugger tries to move the breakpoint, it crashes. By doing the same work ourselves, the debugger doesn't need to resolve the stub secret arg since it never sees a breakpoint in the stub itself. Use UMEntryThunk::GetManagedTarget like what the old system used.
      61a491bd
    • S
      a10c2e6e
    • T
      Fix for small bug in the profile statistics writer (#47656) · 9976a29e
      Tomáš Rylek 提交于
      During my experimentation with callchain optimizations I noticed
      that the profile map only contains meaningful information when
      we're generating PDB or PerfMap at the same time - apparently I
      had the PDB generation turned on during debugging so I overlooked
      this.
      
      Thanks
      
      Tomas
      9976a29e
    • S
      Remove OrderedDictionary usage from ReflectTypeDescriptionProvider (#47473) · 2e9d6121
      Stephen Toub 提交于
      This is showing up a bit on ASP.NET startup paths, and we can be more efficient in how we handle allocations and work.
      2e9d6121
    • B
      Re-enable crossgen2 SPMI collection with EnableExtraSuperPmiQueries=1 (#47655) · 140b9591
      Bruce Forstall 提交于
      Remove workaround after fixed with #47614
      140b9591
    • D
      Adjust some naming (#47662) · c037f8e9
      Dan Moseley 提交于
      c037f8e9
    • T
      Fix for Crossgen2 crash in SuperPMI compilation (issue #47554) (#47614) · 72a4dace
      Tomáš Rylek 提交于
      Based on Andy's advice I propose to harden makeExtraStructQueries
      against drilling into types outside of the current compilation
      version bubble similar to what we're already doing when promoting
      struct fields. I have locally verified that it fixes the crash
      Bruce described in the issue.
      
      Thanks
      
      Tomas
      72a4dace
    • T
      Clean up some of the math intrinsic logic and support constant folding (#47321) · e8f09edc
      Tanner Gooding 提交于
      * Removing unecessary casts to float/double from the classlibnative COMSingle and COMDouble types
      
      * Reordering NI_System_Math_* usages to make it easier to spot errors
      
      * Removing unecessary support for Cos/Sin as "target intrinsics"
      
      * Adding asserts and changing target cost for math intrinsics to be based on IsTargetIntrinsic
      
      * Don't include PAL math wrappers where no additional functionality is needed
      
      * Adding valuenum support for the remaining Math intrinsics, minus FMA and SinCos
      
      * Allow constant folding for all math intrinsics when not IsReadyToRun is false
      
      * Apply formatting patch
      
      * Adding THROW_DECL to match functions to satisfy GCC
      
      * noodes to nodes
      
      * Removing ScaleB named intrinsics
      
      * Update src/coreclr/jit/codegenxarch.cpp
      e8f09edc
    • T
      077489f3
    • H
      Consolidate Bitmap(Type, string) constructor (#46793) · eda8ee92
      Hugh Bellamy 提交于
      * Consolidate Bitmap(Type, string) constructor
      
      * Fix NRE in Bitmap(Type, string)
      eda8ee92
    • T
      Initial implementation of call chain statistics (#47547) · 96f65355
      Tomáš Rylek 提交于
      Add support for producing "callchain profile quality map", a new
      auxiliary output file describing code layout properties w.r.t.
      a given call chain profile.
      
      Sample output for System.Private.CoreLib:
      
      CHARACTERISTIC            | PAIR COUNT | CALL COUNT | PERCENTAGE
      ----------------------------------------------------------------
      ENTRIES TOTAL             |        291 |     266229 |     100.00
      RESOLVED ENTRIES          |        267 |     260172 |      97.72
      UNRESOLVED ENTRIES        |         24 |       6057 |       2.28
      NEAR (INTRA-PAGE) CALLS   |        145 |     109055 |      40.96
      FAR (CROSS-PAGE) CALLS    |        122 |     151117 |      56.76
      
      Thanks
      
      Tomas
      96f65355
    • L
      55a5a0c2
    • B
      98e7ea2a
    • B
      Fixes for SuperPMI collection of crossgen2 (#47609) · c8ce1137
      Bruce Forstall 提交于
      1. Use superpmi.py parallelism (per assembly), not crossgen2 parallelism.
      This is both faster, and it avoids a problem I was seeing of sharing
      violations opening the method context file during collection.
      2. Work around https://github.com/dotnet/runtime/issues/47554:
      crossgen2 doesn't like EnableExtraSuperPmiQueries=1, so disable it
      for crossgen2 collections.
      3. Fix issue when `resolveToken` throws an exception: the resulting
      resolved token structure could be corrupt (it was for crossgen2 in
      a case I saw that led to SPMI crashing), so zero it out and record
      that instead.
      
      With this, there is only one crashing issue for collecting Core_Root
      libraries (Windows x64 Checked), but there are 77835 compilation
      failures on replay (see https://github.com/dotnet/runtime/issues/47540).
      c8ce1137
    • C
      Add APIs to make nint/nuint match Int32 and others (#47595) · f2148079
      Cyl18 提交于
      * Add APIs to make nint/nuint match Int32 and others
      
      * Add default argument to nint/nuint TryFormat
      
      * Fix Api Compat error
      
      * Add test to nint/nuint
      
      * fix test error
      f2148079
  2. 29 1月, 2021 18 次提交
  3. 28 1月, 2021 2 次提交