Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Jan 31 2019 22:23
  • Jan 31 2019 22:00
    MichalStrehovsky commented #6919
  • Jan 31 2019 21:59
    MichalStrehovsky opened #6928
  • Jan 31 2019 20:45
  • Jan 31 2019 19:57
    kouvel commented #6880
  • Jan 31 2019 19:45
    filipnavara commented #6880
  • Jan 31 2019 19:44

    jkotas on master

    Merge pull request #6815 from d… Merge pull request #6839 from d… Merge pull request #6859 from d… and 8 more (compare)

  • Jan 31 2019 19:44
    jkotas closed #6926
  • Jan 31 2019 19:43
    kouvel commented #6880
  • Jan 31 2019 19:26
    kouvel commented #6880
  • Jan 31 2019 19:19

    trylek on master

    Pointer size and ARM64 fixes in… (compare)

  • Jan 31 2019 19:19
    trylek closed #6921
  • Jan 31 2019 18:40
    jkotas synchronize #6926
  • Jan 31 2019 18:40

    jkotas on nmirror

    MethodOnStruct - Fixing Project… Merge pull request #6927 from d… (compare)

  • Jan 31 2019 18:40
    jkotas closed #6927
  • Jan 31 2019 18:32
    dotnet-bot opened #6927
  • Jan 31 2019 17:19

    jkotas on master

    Reverting "Fixing up the UTF8Fo… Add managed implementation of G… (compare)

  • Jan 31 2019 17:19
    jkotas closed #6923
  • Jan 31 2019 17:18

    jkotas on master

    Fix ProjectN build breaks (#692… (compare)

  • Jan 31 2019 17:18
    jkotas closed #6924
dlewis-arcontech
@dlewis-arcontech
@MichalStrehovsky You mentioned before that the inbuild Native AOT marshaller is more efficient than using StringToHGlobal by using StringToAnsiString. If I have a struct which has a member that is decorated as [MarshalAs(UnmanagedType.LPStr)] public String field; Which is being passed over to C++ via a C POD interface. Would this still use the more efficient StringToAnsiString?
RaoulRSV
@RaoulRSV
@MichalStrehovsky. Thanks.
RaoulRSV
@RaoulRSV
CoreRT compiling my main C# project I get a full list of warnings of which I send hereunder an extract. Any idea how to proceed ? Please note that the code contains threads, events from an VB.NET project and dynamic variables.
image.png
masonwheeler
@masonwheeler
@RaoulRSV How well do you understand the whole CoreRT dynamic generics issue?
Because that's what you're running into here.
RaoulRSV
@RaoulRSV
@masonWheeler Not much. Effectively most of the warning contains ... makegenerictype(type[]) " which has " Requiresgenericattibutes" . Is there some doc on this topic ?
masonwheeler
@masonwheeler
I'm not sure if it's documented officially, but it's been discussed pretty extensively on here. Basically, the AOT compiler can't compile dynamic generics (generics whose type is not known at compile time because they're set up by something like MakeGenericType) because... well... the type isn't known at compile time. The workaround is to add the types in question to an XML file that tells the compiler to include those types. The solution is to not use dynamic generics, anywhere you can avoid it.
RaoulRSV
@RaoulRSV
I'll try to avoid dynamics generics together with rd.xml then. Lot of work ! Thanks.
masonwheeler
@masonwheeler
Happy to help :smile:
yowl
@yowl
Why does twitter suck so much at video playback ? https://twitter.com/yowl00/status/1362912752042463237
masonwheeler
@masonwheeler
Because it's Twitter. It sucks so much at everything!
By Twits, for Twits.
Robin Sue
@Suchiman
because twitter uses dynamic quality for the video (can't remember what the tech is called, it's when you slice mp4 into tiny parts of different quality and the browser downloads one based on desired quality dynamically) and the quality / resolution of the video is determined by the size of the playback window which starts out minimized and it does cache the already downloaded low quality video segments so you'd basically have to start the playback with a maximized video player for best quality which you cannot i think
@yowl ... getting off topic though, very cool! xD
yowl
@yowl
I think this was basically working ages ago, when emscripten fixed emscripten-core/emscripten#10809 I just never got round to doing a demo
all bets off when a GC runs though, I've no idea what that will do
Robin Sue
@Suchiman
dew it
yowl
@yowl
RangeError: Maximum call stack size exceeded
at ThreadStore::GetCurrentThreadIfAvailable() (http://localhost:8000/ThreadTest.wasm:wasm-function[19059]:0xd668b1)
at CLREventStatic::Wait(unsigned int, bool, bool) (http://localhost:8000/ThreadTest.wasm:wasm-function[19058]:0xd667b7)
at ThreadStore::WaitForSuspendComplete() (http://localhost:8000/ThreadTest.wasm:wasm-function[19578]:0xd87a9b)
at Thread::WaitForSuspend() (http://localhost:8000/ThreadTest.wasm:wasm-function[19479]:0xd828ec)
at Thread::EnablePreemptiveMode() (http://localhost:8000/ThreadTest.wasm:wasm-function[19487]:0xd82ef9)
at CLREventStatic::Wait(unsigned int, bool, bool) (http://localhost:8000/ThreadTest.wasm:wasm-function[19058]:0xd6681a)
at ThreadStore::WaitForSuspendComplete() (http://localhost:8000/ThreadTest.wasm:wasm-function[19578]:0xd87a9b)
at Thread::WaitForSuspend() (http://localhost:8000/ThreadTest.wasm:wasm-function[19479]:0xd828ec)
at Thread::EnablePreemptiveMode() (http://localhost:8000/ThreadTest.wasm:wasm-function[19487]:0xd82ef9)
at CLREventStatic::Wait(unsigned int, bool, bool) (http://localhost:8000/ThreadTest.wasm:wasm-function[19058]:0xd6681a)
bummer
Robin Sue
@Suchiman
hm....... why is it recursive... interesting
yowl
@yowl

corruption maybe, its not consistent

RuntimeError: memory access out of bounds
    at GcEnumObjectsConservatively(Object**, Object**, void (*)(Object**, ScanContext*, unsigned int), ScanContext*) (http://localhost:8000/ThreadTest.wasm:wasm-function[19202]:0xd6ff3f)
    at RedhawkGCInterface::EnumGcRefsInRegionConservatively(RtuObjectRef*, RtuObjectRef*, void*, void*) (http://localhost:8000/ThreadTest.wasm:wasm-function[19136]:0xd6cd25)
    at GcScanWasmShadowStack(void*, void*) (http://localhost:8000/ThreadTest.wasm:wasm-function[19506]:0xd83d17)
    at Thread::GcScanRoots(void*, void*) (http://localhost:8000/ThreadTest.wasm:wasm-function[19507]:0xd83d76)
    at GCToEEInterface::GcScanRoots(void (*)(Object**, ScanContext*, unsigned int), int, int, ScanContext*) (http://localhost:8000/ThreadTest.wasm:wasm-function[19201]:0xd6fd09)
    at GCScan::GcScanRoots(void (*)(Object**, ScanContext*, unsigned int), int, int, ScanContext*) (http://localhost:8000/ThreadTest.wasm:wasm-function[20544]:0xe63181)
    at WKS::gc_heap::mark_phase(int, int) (http://localhost:8000/ThreadTest.wasm:wasm-function[20155]:0xdeace8)
    at WKS::gc_heap::gc1() (http://localhost:8000/ThreadTest.wasm:wasm-function[20149]:0xde273e)
    at WKS::gc_heap::garbage_collect(int) (http://localhost:8000/ThreadTest.wasm:wasm-function[20082]:0xdc9549)
    at WKS::GCHeap::GarbageCollectGeneration(unsigned int, gc_reason) (http://localhost:8000/ThreadTest.wasm:wasm-function[20079]:0xdc80d9)

I still have some memory allocation changes that are not PR'ed. May or may not help

yowl
@yowl

Made some small progress embedding LLVM in clrjit, but now.... This code is causing a problem https://github.com/llvm/llvm-project/blob/183bbad1d78a4bf445ec4db1ce01673f6a7feb37/llvm/include/llvm/ADT/APFloat.h#L624-L630 :

  DoubleAPFloat &operator=(DoubleAPFloat &&RHS) {
    if (this != &RHS) {
      this->~DoubleAPFloat();
      new (this) DoubleAPFloat((std::move)(RHS));
    }
    return *this;
  }

From my understanding its a bit of c++ black magic to create a new object over the top of the existing one new (this)..... The error however with msbuild /v:normal is

1>    E:\GitHub\llvm-project\llvm\include\llvm\ADT\APFloat.h(624,1): error C2665: 'operator new': none of the 10 overloads could convert all the argument types
1>    C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\VC\Tools\MSVC\14.28.29333\include\vcruntime_new.h(53,17): message : could be 'void *operator new(size_t,const std::nothrow_t &) noexcept'
1>    E:\GitHub\runtimelab\src\coreclr\jit\alloc.h(253,22): message : or       'void *operator new(size_t,CompAllocator)'
1>    E:\GitHub\runtimelab\src\coreclr\jit\hostallocator.h(45,22): message : or       'void *operator new(size_t,HostAllocator)'
1>    E:\GitHub\runtimelab\src\coreclr\inc\utilcode.h(4667,16): message : or       'void *operator new(size_t,const CExecutable &)'
1>    E:\GitHub\runtimelab\src\coreclr\inc\new.hpp(19,16): message : or       'void *operator new(size_t,const NoThrow &) noexcept'
1>    E:\GitHub\llvm-project\llvm\include\llvm\ADT\APFloat.h(624,1): message : while trying to match the argument list '(unsigned __int64, llvm::detail::DoubleAPFloat *)'

so is clr redefining the new operator so that this kind of new with placement syntax is not going to work?

RaoulRSV
@RaoulRSV
Good morning. I am unable to coreRT compile a project . Console says
image.png
my rd.xml file is
<Directives xmlns="http://schemas.microsoft.com/netfx/2013/01/metadata">
<Application>
<Assembly Name="System.Text.Json">
<!-- for serialization of WeatherForecast -->
<Type Name="System.Text.Json.JsonPropertyInfoNotNullable`4[[SystemTextJsonSerialization.WeatherForecast,SystemTextJsonSerialization], [System.DateTimeOffset,System.Private.CoreLib], [System.DateTimeOffset,System.Private.CoreLib], [System.DateTimeOffset,System.Private.CoreLib]]" Dynamic="Required All" />
<Type Name="System.Text.Json.JsonPropertyInfoNotNullable`4[[SystemTextJsonSerialization.WeatherForecast,SystemTextJsonSerialization],[System.Int32,System.Private.CoreLib],[System.Int32,System.Private.CoreLib],[System.Int32,System.Private.CoreLib]]" Dynamic="Required All" />
<!-- for serialization of WeatherForecastWithNullable -->
<Type Name="System.Text.Json.JsonPropertyInfoNotNullable`4[[SystemTextJsonSerialization.WeatherForecastWithNullable,SystemTextJsonSerialization],[System.DateTimeOffset,System.Private.CoreLib],[System.DateTimeOffset,System.Private.CoreLib],[System.DateTimeOffset,System.Private.CoreLib]]" Dynamic="Required All" />
<Type Name="System.Text.Json.JsonPropertyInfoNullable`2[[SystemTextJsonSerialization.WeatherForecastWithNullable,SystemTextJsonSerialization],[System.Int32,System.Private.CoreLib]]" Dynamic="Required All" />
</Assembly>
</Application>
</Directives>
Any idea?
another try is
RUSshy
@RUSshy
Hmm, i got a user, his system language is polish, and float parsing (from string) is kinda not working for him, are there known issues with that kind of things? i suspect global invariant thingy
RUSshy
@RUSshy
Also is there a way to use an old version with .net 3? this one specifically: Version="1.0.0-alpha-29228-02"
RUSshy
@RUSshy

if (float.TryParse(latestVersion, out var latest))
This returns false on his computer, the input string is "100"

    <PropertyGroup Condition="true">
        <IlcGenerateMapFile>false</IlcGenerateMapFile>

        <IlcDisableReflection>false</IlcDisableReflection>

        <RootAllApplicationAssemblies>false</RootAllApplicationAssemblies>
        <IlcGenerateCompleteTypeMetadata>false</IlcGenerateCompleteTypeMetadata>

        <IlcGenerateStackTraceData>false</IlcGenerateStackTraceData>
        <IlcInvariantGlobalization>true</IlcInvariantGlobalization>
        <IlcOptimizationPreference>Size</IlcOptimizationPreference>
        <IlcFoldIdenticalMethodBodies>false</IlcFoldIdenticalMethodBodies>
    </PropertyGroup>

Config i used, i made sure reflection free isn't enable to avoid problems

CoreRT: <PackageReference Include="Microsoft.DotNet.ILCompiler" Version="6.0.0-preview.2.21122.5" />
Dotnet: 5.0.103

Does Version="6.0.0-preview.2.21122.5" indicates it is for dotnet 6 preview 2?
RUSshy
@RUSshy
Switching to: <IlcInvariantGlobalization>false</IlcInvariantGlobalization> fixed the issue, so looks like something broken, should i open issue?
masonwheeler
@masonwheeler

So much tag bloat, so little content!

Some people, when presented with a problem, think “I know, I’ll use XML.” <Problem:Worsening> <Problem:TimeDescription>Now</Problem:TimeDescription> <Problem:Posessive>they have</Problem:Posessive> <Problem:Quantity>many, many</Problem:Quantity> <Problem:WorseningDescription>more problems</Problem:WorseningDescription> </Problem:Worsening>

RUSshy
@RUSshy
i hate XML and i hate csproj even more
ahopper
@ahopper
@masonwheeler :) you just need to add RDF to make it really clear.
yowl
@yowl
remove the tags and you get the perfect solution: yml
:sarcasm face:
Andrii Kurdiumov
@kant2002
Why not use Protobuf directly? Anything else inefficient. Or if you really on the edge use English!
RaoulRSV
@RaoulRSV
Concerning same question. I narrowed the question :

Error message was : System.Text.Json.Serialization.Converters.DictionaryOfTkeyTValueConverter<System.Collections.Generic.Dictionary<System.String,System.Object>,System.String,System.Object> is missing metadata

I tried with in rd.xml : <Type Name="System.Text.Json.Serialization.Converters.DictionaryOfTkeyTValueConverter`3[ [System.Collections.Generic.Dictionary`2[[System.String,System.Private.CoreLib],[System.Object,System.Private.CoreLib]]+KeyCollection, [System.String,System.Private.CoreLib],[System.Object,System.Private.CoreLib]]" Dynamic="Required All" />

RaoulRSV
@RaoulRSV
No success so far
yowl
@yowl
If you remove "+KeyCollection" ?
RaoulRSV
@RaoulRSV
@yowl removing "+keyCollection gives the same error message.
RaoulRSV
@RaoulRSV
@yowl . I did work the error around by making "Dictionary(of string, object)" to be "String[]". It seems to work properly. Thanks for your attention.
yowl
@yowl
DictionaryOfTkeyTValueConverter has a capital "K" for "Key". Not sure if that helps
I use this for coding these days:
image.png
Andrii Kurdiumov
@kant2002
I thought about having ILC compiler suggests you to add Type directives with all syntax on this error. Not sure if this would be accepted