Giter VIP home page Giter VIP logo

hornetsnest's People

Contributors

anupnayakgithub avatar foxjas avatar hornet-gt avatar kaatish avatar kasimirgabert avatar lilian92 avatar ogreen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

hornetsnest's Issues

cuFreeAux nullifies the pointer before invoking the cuMemFree

https://github.com/hornet-gt/XLib/blob/ded93b18da8bed55f1c96bb8e6e83e8078ffd969/include/Device/Util/SafeCudaAPI.cuh

template<typename T>
typename std::enable_if<std::is_pointer<T>::value>::type
cuFreeAux(const char* file, int line, const char* func_name, T& ptr)  noexcept {
    using R    = typename xlib::remove_const_ptr<T>::type;
    auto& ptr1 = const_cast<R&>(ptr);
   //Issue: The following two lines need to be switched
    ptr1 = nullptr;
   cudaErrorHandler(cudaFree(ptr1), "cudaFree", file, line, func_name);
}

This issue seems like fixed.

The initialization function doesn’t deallocate the memory before reallocating

https://github.com/hornet-gt/hornet/blob/master/include/Core/DataLayout/DataLayout.i.cuh

One example shown below and there are additional similar issues. :

178 template<typename... TArgs> 
179 void AoS<TArgs...>::initialize(const void* (&array)[sizeof...(TArgs)], 
180                                int num_items) noexcept { 
181     _num_items = num_items; 
182     _h_ptr     = new AoSData<TArgs...>[num_items]; 
183     for (auto i = 0; i < num_items; i++) 
184         _h_ptr[i] = AoSData<TArgs...>(array, i); 
185     cuMalloc(_d_ptr_, num_items); //Issue: _d_ptr_ should have been freed before allocating 
186     cuMemcpyToDevice(_h_ptr, num_items, _d_ptr); 
187 }  

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.