Giter Site home page Giter Site logo

Comments (2)

adayton1 avatar adayton1 commented on June 21, 2024 1

These are the things we are currently use or would use. We have implementations of almost all of these in CARE.

Containers: (If needed, these could be views except for array)

  • Something like std::array
  • Something like std::vector (we don't use push_back)
  • Something like std::map or std::flat_map that gives binary search capability
  • Something like std::set or std::flat_set that gives binary search capability

Algorithms that act on scalars:

  • abs (I know there is fabs, but I would like a templated version that always does the right thing)
  • max/min (again there are fmin and fmax, but a templated version would be great, especially an initializer list and/or variadic template version to handle any number of scalars) - we definitely want something to get rid of the MAX and MIN macros that many codes have defined.
  • swap
  • copysign
  • Templated versions of a lot of math functions would be nice, but perhaps that is out of the scope or belongs somewhere else (maybe all of these except swap belong somewhere else)

Algorithms that act on arrays (note that these are at the level of a single thread, not launching kernels, so "sequential" I guess):

  • min/max/minmax
  • find/search
  • copy
  • is_sorted
  • binary_search
  • lower_bound
  • upper_bound
  • sort
  • unique

Algorithms that act on arrays and do launch kernels:

  • fill
  • copy
  • min/max/minmax
  • find/search
  • count
  • iota
  • accumulate
  • inclusive/exclusive_scan
  • is_sorted
  • sort
  • unique
  • compress (I'm not sure if there is a std algorithm equivalent, but basically given an array and a list of indices, makes a new array with only the selected indices or everything but the given indices)
  • sort_pairs

There's probably other algorithms that I'm missing, but this is a pretty core set.

from raja.

MrBurmark avatar MrBurmark commented on June 21, 2024

@trws Here's an idea to potentially reduce code duplication across projects by expanding camp to have more containers/views and algorithms that are commonly used in device code.

from raja.

Related Issues (20)

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.