Giter VIP home page Giter VIP logo

spansample's People

Contributors

aalmada avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

spansample's Issues

Exception While Running Native Benchmark

Hello,

I saw in your excellent blog post the use of the benchmarks here. When checking out the code, however, there seems to be a NativeEnumerable benchmark that is not discussed in the blog post. Not that I can see, at least.

This. of course, gets me curious to download the code and try it out to see how it fares with the others. Unfortunately, it results in an exception which I will provide here:

System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Runtime.InteropServices.SEHException: External component has thrown an exception.
   at SpanSample.Native.StreamRead(NativeStreamHandle stream, Int32& buffer, UIntPtr size)
   at SpanSample.NativeEnumerable.Enumerator.MoveNext() in C:\Users\..\Downloads\SpanSample-master\SpanSample\NativeEnumerable.cs:line 54
   at SpanSample.EnumerationBenchmarks.NativeEnumerable() in C:\Users\..\Downloads\SpanSample-master\SpanSample\EnumerationBenchmarks.cs:line 156
   at BenchmarkDotNet.Autogenerated.Runnable_0.WorkloadActionNoUnroll(Int64 invokeCount) in C:\Users\..\Downloads\SpanSample-master\SpanSample\bin\Release\netcoreapp2.1\bded5edd-b23b-45eb-8855-ac509f2a26ce\bded5edd-b23b-45eb-8855-ac509f2a26ce.notcs:line 466
   at BenchmarkDotNet.Engines.Engine.RunIteration(IterationData data)
   at BenchmarkDotNet.Engines.EngineFactory.Jit(Engine engine, Int32 jitIndex, Int32 invokeCount, Int32 unrollFactor)
   at BenchmarkDotNet.Engines.EngineFactory.CreateReadyToRun(EngineParameters engineParameters)
   at BenchmarkDotNet.Autogenerated.Runnable_0.Run(IHost host) in C:\Users\..\Downloads\SpanSample-master\SpanSample\bin\Release\netcoreapp2.1\bded5edd-b23b-45eb-8855-ac509f2a26ce\bded5edd-b23b-45eb-8855-ac509f2a26ce.notcs:line 143
   --- End of inner exception stack trace ---
   at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor, Boolean wrapExceptions)
   at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at BenchmarkDotNet.Autogenerated.UniqueProgramName.AfterAssemblyLoadingAttached(String[] args) in C:\Users\..\Downloads\SpanSample-master\SpanSample\bin\Release\netcoreapp2.1\bded5edd-b23b-45eb-8855-ac509f2a26ce\bded5edd-b23b-45eb-8855-ac509f2a26ce.notcs:line 59

A couple other notes:

  • I had to update the Windows SDK to a newer version
  • Same with some Nuget packages (expected of course)
  • When switching to Release mode, the x64 path was not there and results in an exception when trying to copy Native. It turns out that Release mode is set to Win32 for the Native project. I am not sure if this is due to updating the SDK, however (I am not very familiar with C++ projects).

Otherwise, this is extremely valuable and informative. Thank you for putting this together!
-Michael

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.